Last active
July 17, 2022 16:48
-
-
Save mahdyar/d6a1a8bda6074427e93f218712addc1f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wir(){ | |
NAME=$(sed 's/ /_/g' <<< "$@") | |
INITIAL=$(echo $NAME | head -c 1) | |
IMDB_ID=$(curl -ks "https://v2.sg.media-imdb.com/suggestion/$INITIAL/$NAME.json" | jq -r '.d[0].id') | |
LINK="https://wir31.site/${IMDB_ID}/" | |
curl -ks "$LINK" | lynx -dump -nonumbers -listonly -stdin | grep -e '.mkv' -e '.mp4' | grep 'http://' | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
WIR Downloader
Requirements
You should have
jq
,lynx
andcurl
installed.On macOS:
Usage
Add this function to your
~/.bashrc
,~/.zshrc
, etc.Preview