Skip to content

Instantly share code, notes, and snippets.

@dorianbayart
Last active March 19, 2024 09:44
Show Gist options
  • Save dorianbayart/1684ef0bc72077fe723780c7e92512be to your computer and use it in GitHub Desktop.
Save dorianbayart/1684ef0bc72077fe723780c7e92512be to your computer and use it in GitHub Desktop.
Easily download a video using youtube-dl
#!/bin/bash
# This script downloads a video with the highest available video and audio qualities
# Requirements:
# brew install youtube-dl
# chmod +x youtube-dl.sh
# Usage:
# ./youtube-dl.sh
echo -n "\n\nPlease input the URL you want to download the video from: "
read url
echo "\n\nThe download should start very soon, please wait ..."
youtube-dl -o 'youtube-dl/%(title)s.%(ext)s' -f best ${url} --restrict-filenames
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment