Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ######################
- # START # v1ral_ITS #
- ######################
- A bash wrapper script that prompts for the format, which includes all available renditions, including audio-only, video-only.
- Accepts both absolute youtube URLs and video IDs.
- ############################################################################################################################
- #!/usr/bin/env bash
- # Download youtube video with desired quality
- # youtube-dl accepts both fully qualified URLs and video id's such as AQcQgfvfF1M
- url="$*"
- echo "Fetching available formats for $url..."
- youtube-dl -F "$url"
- read -p "Please enter the desired quality code: " FORMAT
- echo "Streaming with quality $FORMAT..."
- mpv --cache=1024 $(youtube-dl -f $FORMAT -g "$url")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement