mirror of
https://github.com/CoolnsX/repos_scripts.git
synced 2026-03-01 04:10:35 +05:30
added user-agent in scripts
This commit is contained in:
4
nsfw
4
nsfw
@@ -3,7 +3,7 @@
|
||||
[ -z "$*" ] && printf "enter(paste) number or link:" && read -r num || num=$*
|
||||
num=$(printf "$num" | cut -d\/ -f5)
|
||||
dir="$HOME/.cache/$num"
|
||||
mkdir -pv $dir
|
||||
mkdir -p $dir
|
||||
trap "rm -rf $dir;exit 0" INT HUP
|
||||
pg=$(curl -s "https://nhentai.net/g/$num/1/" | sed -nE 's/.*pages">(.*)<\/span><.*/\1/p')
|
||||
echo "pages : $pg"
|
||||
@@ -19,4 +19,4 @@ echo "waiting 5 sec for pages to download completely"
|
||||
sleep 5
|
||||
echo "concatenating pages to pdf"
|
||||
convert "$dir/*" "$num.pdf" && printf "saved pdf as $num.pdf\nopening pdf...enjoy 😏😏" && setsid -f xdg-open "$num.pdf"
|
||||
rm -rvf $dir
|
||||
rm -rf $dir
|
||||
|
||||
Reference in New Issue
Block a user