Package Exports
- python-youtube-downloader
- python-youtube-downloader/downloader.py
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (python-youtube-downloader) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
Python Youtube Downloader
A simple command-line application to download YouTube videos as MP3 (audio) or MP4 (video). Optionally saves to an external drive.
Prerequisites
- Python 3.x
- yt-dlp: Installed via
pip install yt-dlp - ffmpeg: Required for audio conversion.
- macOS:
brew install ffmpeg - Windows: Download from ffmpeg.org and add to PATH.
- Linux:
sudo apt install ffmpeg
- macOS:
Installation
Option A: npm (global CLI)
Install globally and run from anywhere:
npm install -g python-youtube-downloaderThen use:
youtube-downloader
# or
python-youtube-downloaderOption B: From source
- Clone or download this repository.
- Install the required Python library:
pip install yt-dlp
Prerequisites (for both options): Python 3, yt-dlp (pip install yt-dlp), and ffmpeg (for MP3/MP4 conversion).
Usage
Run the script and enter the YouTube URL when prompted. Choose MP3 (audio only) or MP4 (video). If an external drive named SWIM PRO is connected, files are saved there; otherwise they go to the current folder.
python downloader.py
# or, if installed via npm:
youtube-downloaderOr with link and format:
python downloader.py "https://youtu.be/VIDEO_ID" mp3
python downloader.py "https://youtu.be/VIDEO_ID" mp4
youtube-downloader "https://youtu.be/VIDEO_ID" mp4