diff --git a/ani-new b/ani-new index ccc1ceb..38e9166 100755 --- a/ani-new +++ b/ani-new @@ -2,8 +2,9 @@ down () { notify-send "$3 links fetched.." -r $tmp - choice=$(printf "download\nwatch" | dmenu -p "??") - [ "$choice" = "watch" ] && setsid -f mpv --referrer="$1" "$2" && notify-send "opening $url in mpv" -r $tmp && exit 0 + choice=$(printf "download\nwatch\nnext mirror" | dmenu -p "??") + [ "$choice" = "watch" ] && setsid -f mpv --referrer="$1" "$2" --force-media-title="$url" && notify-send "opening $url in mpv" -r $tmp && exit 0 + [ "$choice" = "next mirror" ] && return 0 notify-send "Downloading $url" -r $tmp case $2 in *m3u*) @@ -14,16 +15,21 @@ down () { exit 0 } +run () { + curl -s "$base_url?page=1" -A "$agent" | sed -nE 's_.*_\1_p' & + curl -s "$base_url?page=2" -A "$agent" | sed -nE 's_.*_\1_p' & +} + base_url=https://goload.pro -agent="Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.54 Safari/537.36" +agent="Mozilla/5.0 (Linux; Android 11; moto g(9) power) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.41 Mobile Safari/537.36" trap "exit 0" INT HUP -tmp=$(notify-send "Parsing $base_url.. Please wait..." -p) -url=$(curl -A "$agent" -s "$base_url" | sed -nE 's_.*_\1_p' | dmenu -p "Select Anime: ") +tmp=$(notify-send "Parsing $base_url.. Please wait..." -t 1500 -p) +[ -z "$*" ] && url=$(run | dmenu -p "Select Anime: " -l 20) || url=$* [ -z "$url" ] && notify-send -u "critical" "No anime selected" -r $tmp && exit 0 || notify-send "Loading Episode $url.." -r $tmp refr=$(curl -A "$agent" -s "$base_url/videos/$url" | sed -nE 's/.*iframe src="(.*)" al.*/\1/p') notify-send "Fetching Embed links" -r $tmp -resp="$(curl -A "$agent" -s "https:$refr")" -links=$(printf "%s" "$resp" | sed -nE 's/.*data-status="1".*data-video="(.*)">.*/\1/p') +resp="$(curl -A "$agent" -s "https:$refr" | sed -nE 's/.*class="container-(.*)">/\1/p ; s/.*class="wrapper container-(.*)">/\1/p ; s/.*class=".*videocontent-(.*)">/\1/p ; s/.*data-value="(.*)">.*/\1/p ; s/.*data-status="1".*data-video="(.*)">.*/\1/p')" +links=$(printf "%s" "$resp" | sed -n '5,$ p') notify-send "Fetching mp4upload links" -r $tmp mp4up_link=$(printf "$links" | grep "mp4upload") @@ -37,17 +43,24 @@ sleep 0.5 [ -z "$dood_link" ] || dood_video=$(curl -A "$agent" -s "https://dood.ws${dood_link}" | sed -nE "s/.*window.open.*'(.*)',.*/\1/p") [ -z "$dood_video" ] || down "https://dood.ws/d/$dood_id" "$dood_video" "doodstream" -notify-send "Fetching goload links" -r $tmp -id=$(printf "%s" "$refr" | sed -nE 's/.*id=(.*)&title.*/\1/p') -secret_key=$(printf "%s" "$resp" | sed -nE 's/.*class="container-(.*)">/\1/p' | tr -d "\n" | od -A n -t x1 | tr -d " |\n") -iv=$(printf "%s" "$resp" | sed -nE 's/.*class="wrapper container-(.*)">/\1/p' | tr -d "\n" | od -A n -t x1 | tr -d " |\n") -second_key=$(printf "%s" "$resp" | sed -nE 's/.*class=".*videocontent-(.*)">/\1/p' | tr -d "\n" | od -A n -t x1 | tr -d " |\n") -token=$(printf "%s" "$resp" | sed -nE 's/.*data-value="(.*)">.*/\1/p' | base64 -d | openssl enc -d -aes256 -K "$secret_key" -iv "$iv" | sed -nE 's/.*&(token.*)/\1/p') -ajax=$(printf '%s' "$id" |openssl enc -e -aes256 -K "$secret_key" -iv "$iv" | base64) -video="$(curl -A "$agent" -s -H "X-Requested-With:XMLHttpRequest" "${base_url}/encrypt-ajax.php?id=${ajax}&alias=${id}&${token}" | sed -e 's/{"data":"//' -e 's/"}/\n/' -e 's/\\//g' | base64 -d | openssl enc -d -aes256 -K "$second_key" -iv "$iv" | sed -e 's/\].*/\]/' -e 's/\\//g' | grep -Eo 'https:\/\/[-a-zA-Z0-9@:%._\+~#=][a-zA-Z0-9][-a-zA-Z0-9@:%_\+.~#?&\/\/=]*' | head -4 | tail -1)" -[ -z "$video" ] || down "$base_url" "$video" "goload" - notify-send "Fetching xstreamcdn links" -r $tmp fb_id=$(printf "$links" | sed -n "s_.*fembed.*/v/__p") [ -z "$fb_id" ] || fb_video=$(curl -A "$agent" -s -X POST "https://fembed-hd.com/api/source/$fb_id" -H "x-requested-with:XMLHttpRequest" | sed -e 's/\\//g' -e 's/.*data"://' | tr "}" "\n" | sed -nE 's/.*file":"(.*)","label.*/\1/p' | tail -1) [ -z "$fb_video" ] || down "https://fembed-hd.com/v/$fb_id" "$fb_video" "xstreamcdn" + +id=$(printf "%s" "$refr" | sed -nE 's/.*id=(.*)&title.*/\1/p') + +notify-send "Fetching xstreamcdn links" -r $tmp +[ -z "$id" ] || ani_video="$(curl -s "https://animixplay.to/api/live$(printf "%sLTXs3GrU8we9O%s" "$id" "$(printf "$id" | base64)" | base64)" -A "$agent" -I | sed -nE 's_location: (.*)_\1_p' | cut -d"#" -f2 | base64 -d)" +[ -z "$ani_video" ] || down "https://animixplay.to" "$ani_video" "animixplay" + +notify-send "Fetching goload links" -r $tmp +secret_key=$(printf "%s" "$resp" | sed -n '2p' | tr -d "\n" | od -A n -t x1 | tr -d " |\n") +iv=$(printf "%s" "$resp" | sed -n '3p' | tr -d "\n" | od -A n -t x1 | tr -d " |\n") +second_key=$(printf "%s" "$resp" | sed -n '4p' | tr -d "\n" | od -A n -t x1 | tr -d " |\n") +token=$(printf "%s" "$resp" | head -1 | base64 -d | openssl enc -d -aes256 -K "$secret_key" -iv "$iv" | sed -nE 's/.*&(token.*)/\1/p') +ajax=$(printf '%s' "$id" | openssl enc -e -aes256 -K "$secret_key" -iv "$iv" -a) +video="$(curl -A "$agent" -s -H "X-Requested-With:XMLHttpRequest" "${base_url}/encrypt-ajax.php?id=${ajax}&alias=${id}&${token}" | sed -e 's/{"data":"//' -e 's/"}/\n/' -e 's/\\//g' | base64 -d | openssl enc -d -aes256 -K "$second_key" -iv "$iv" | sed -e 's/\].*/\]/' -e 's/\\//g' | grep -Eo 'https:\/\/[-a-zA-Z0-9@:%._\+~#=][a-zA-Z0-9][-a-zA-Z0-9@:%_\+.~#?&\/\/=]*' | head -4 | tail -1)" +[ -z "$video" ] || down "$base_url" "$video" "goload" + +notify-send -u critical "no more mirror links..sorry" -r $tmp && exit 0 diff --git a/nsfw b/nsfw index 11d6d47..a1f5f2e 100755 --- a/nsfw +++ b/nsfw @@ -1,22 +1,18 @@ #!/bin/sh [ -z "$*" ] && printf "enter(paste) number or link:" && read -r num || num=$* -num=$(printf "$num" | cut -d\/ -f5) +num=$(printf "$num" | cut -d'/' -f5) dir="$HOME/.cache/$num" 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" +printf "\033[1;35m pages : $pg\n\033[1;33mDownloading..\033[0m" for i in $(seq $pg);do - url=$(curl -s "https://nhentai.net/g/$num/$i/" | sed -nE 's/.*" "\n") -name=$(printf "%s" "$data" | sed -nE 's/^\[.*Please\] (.*)/\1/p' | dmenu -l 25 -p "Search anime:") +data=$(curl -s "https://subsplease.org/rss/?r=1080" | sed 's//\n/g') +name=$(printf "%s" "$data" | sed -nE 's_^.*Please\] (.*).*size>(.*) \1_p' | dmenu -l 25 -p "Search anime:") [ -z "$name" ] && notify-send -u critical "Err.. Query empty" -r $tmp && exit 0 -id=$(printf "$name" | sed -n -e 's/.*\[\(.*\)\].*/\1/p') -magnet=$(printf "%s" "$data" | grep "$id%" | sed 's/amp;//g') +id=$(printf "$name" | sed -nE 's/.*\[(.*)\].*/\1/p') +magnet=$(printf "%s" "$data" | sed -nE "s_.*(.*$id.*).*_\1_p" | sed 's/amp;//g') setsid -f st -e $HOME/repos_scripts/torrent "$magnet" diff --git a/speedtest b/speedtest index a5a0e7c..37e33b0 100755 Binary files a/speedtest and b/speedtest differ diff --git a/st-0.8.4/config.def.h b/st-0.8.4/config.def.h index b785b44..e7aad60 100644 --- a/st-0.8.4/config.def.h +++ b/st-0.8.4/config.def.h @@ -5,7 +5,7 @@ * * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html */ -static char *font = "JetBrains Mono NL:style=Regular:pixelsize=16:antialias=true:autohint=true"; +static char *font = "JetBrains Mono NL:style=Regular:pixelsize=15:antialias=true:autohint=true"; static int borderpx = 0; @@ -27,8 +27,8 @@ char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400"; char *vtiden = "\033[?6c"; /* Kerning / character bounding-box multipliers */ -static float cwscale = 0.9; -static float chscale = 0.9; +static float cwscale = 1.0; +static float chscale = 1.0; /* * word delimiter string diff --git a/st-0.8.4/config.h b/st-0.8.4/config.h index b785b44..e7aad60 100644 --- a/st-0.8.4/config.h +++ b/st-0.8.4/config.h @@ -5,7 +5,7 @@ * * font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html */ -static char *font = "JetBrains Mono NL:style=Regular:pixelsize=16:antialias=true:autohint=true"; +static char *font = "JetBrains Mono NL:style=Regular:pixelsize=15:antialias=true:autohint=true"; static int borderpx = 0; @@ -27,8 +27,8 @@ char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400"; char *vtiden = "\033[?6c"; /* Kerning / character bounding-box multipliers */ -static float cwscale = 0.9; -static float chscale = 0.9; +static float cwscale = 1.0; +static float chscale = 1.0; /* * word delimiter string diff --git a/st-0.8.4/st b/st-0.8.4/st index c8cfb5e..ff42501 100755 Binary files a/st-0.8.4/st and b/st-0.8.4/st differ diff --git a/st-0.8.4/st.o b/st-0.8.4/st.o index b32d52a..133c620 100644 Binary files a/st-0.8.4/st.o and b/st-0.8.4/st.o differ diff --git a/st-0.8.4/x.o b/st-0.8.4/x.o index 1bdb49c..3f91781 100644 Binary files a/st-0.8.4/x.o and b/st-0.8.4/x.o differ diff --git a/yt-music b/yt-music new file mode 100755 index 0000000..82bd9e9 --- /dev/null +++ b/yt-music @@ -0,0 +1,14 @@ +#!/bin/sh +# download/stream high quality mp3 music from youtube using ytmp3.com site +#this script give link which can be used to download or stream music + +[ -z "$*" ] && id=$(printf "" | dmenu -p "Paste yt-link(ctrl + y):") || id=$* +id=$(printf "$id" | cut -d"=" -f2 | cut -d"/" -f4) +printf "\033[1;34mFetching page" +token=$(curl -s "https://ytmp3x.com/$id" | sed -nE 's/.*token":"(.*)","adg.*/\1/p') +printf "\33[2K\r\033[1;35mFetching tokens" +[ -z "$token" ] || token2=$(curl -s -X POST -H "X-Requested-With:XMLHttpRequest" 'https://ytmp3x.com/ajax' -d "purpose=audio&token=$token" | sed -nE 's/.*audio":"(.*)"\}/\1/p') +printf "\33[2K\r\033[1;36mFetching mp3 link" +[ -z "$token2" ] || url=$(curl -s -X POST -H "X-Requested-With:XMLHttpRequest" "https://ytmp3x.com/ajax" -d "purpose=download&token=$token2&b=320&r=https://ytmp3x.com/$id" | tr -d '\\' | sed -nE 's/.*mp3url":"(.*)"\}/\1/p') +[ -z "$url" ] && printf "\33[2K\r\033[1;31m unable to fetch mp3 link\033[0m" && exit 0 +printf "\32[2K\r\033[0m %s\n" "$url"