mirror of
https://github.com/Phantop/dotfiles
synced 2024-11-28 17:42:47 +00:00
Fish: ao3dl
This commit is contained in:
parent
bbd49a5129
commit
34691683e3
9
.config/fish/functions/ao3dl.fish
Normal file
9
.config/fish/functions/ao3dl.fish
Normal file
|
@ -0,0 +1,9 @@
|
|||
# Defined in /tmp/fish.qhqZn9/ao3dl.fish @ line 2
|
||||
function ao3dl
|
||||
set dir (sed (math (grep -n '<title>' $argv | cut -d: -f1) + 1)!d $argv | sed -e 's/^[ \t]*//')
|
||||
mkdir $dir; cd $dir
|
||||
for i in (grep works/[0-9]\* ../$argv -o | uniq | sed 's/works\///g' | sed '/^$/d')
|
||||
dl https://download.archiveofourown.org/downloads/$i/\*.epub
|
||||
end
|
||||
cd ..
|
||||
end
|
Loading…
Reference in a new issue