mirror of
https://github.com/CoolnsX/repos_scripts.git
synced 2025-12-20 15:25:20 +05:30
pay no attention to the man behind the curtain
This commit is contained in:
3
tor-bay
3
tor-bay
@@ -28,7 +28,8 @@ esac
|
||||
[ -z "$query" ] && exit 0
|
||||
[ "$os" = "linux" ] && tmp=$(notify-send "Searching query" -p)
|
||||
query=$(printf "%s" "$query" | tr " " "+")
|
||||
data=$(curl -s "https://apibay.org/q.php?q=$query" | sed 's/},/}\n/g' | tr -d "[]")
|
||||
data=$(curl -s "https://apibay.org/q.php?q=$query" | tee data | sed 's/},/}\n/g' | tr -d "[]")
|
||||
|
||||
[ "$os" = "linux" ] && notify-send "tidying up data" -r $tmp
|
||||
size=$(printf "%s" "$data" | sed -nE 's/.*name.*size":"(.*)",.*user.*/\1/p')
|
||||
name_seed=$(printf "%s" "$data" | sed -nE 's/.*name":"(.*)","info_hash.*seeders":"(.*)",.*num.*/\2] \1/p')
|
||||
|
||||
Reference in New Issue
Block a user