Skip to content

Instantly share code, notes, and snippets.

@DominikPeters
Created December 2, 2021 04:28
Show Gist options
  • Save DominikPeters/92a2054f0a13604b25cd555b34872cd1 to your computer and use it in GitHub Desktop.
Save DominikPeters/92a2054f0a13604b25cd555b34872cd1 to your computer and use it in GitHub Desktop.
AppleScript to call youtube-dl on the URL currently displayed by Google Chrome
# I use this together with BetterTouchTool
tell application "Google Chrome"
set theURL to URL of active tab of first window as string
end tell
tell application "Terminal"
do script "cd ~/Downloads && youtube-dl '" & theURL & "'"
end tell
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment