-
Notifications
You must be signed in to change notification settings - Fork 1k
Install yt‐dlp
The youtube-dl tool, while once popular for downloading videos from YouTube and other platforms, has seen a slowdown in updates and may not work reliably with newer changes to these platforms. As an alternative, the community has developed a more up-to-date and feature-rich tool called yt-dlp, which is seen as an improved fork of youtube-dl.
If you've been using youtube-dl and have been facing issues, it's recommended to switch to yt-dlp for a better experience.
-
Update System Repositories: Before installing any new software, it's a good practice to update the system's repositories to ensure you're accessing the latest versions of packages.
sudo apt update
-
Install yt-dlp:
yt-dlpcan be installed usingpip, Python's package installer. If you don't havepipinstalled, you can install it using the package manager:sudo apt install python3-pip
Once
pipis installed, you can installyt-dlp:sudo pip3 install -U yt-dlp
-
Updating yt-dlp: Since
yt-dlpis installed viapip, you can easily update it using the following command:sudo pip3 install -U yt-dlp
-
Open Crontab: To edit the
crontabfor the current user, use the following command:crontab -e
-
Add Daily Update Command: At the end of the file, add the following line to ensure
yt-dlpupdates every day at a specific time (e.g., 2:30 AM):30 2 * * * /usr/local/bin/pip3 install -U yt-dlp -
Save and Exit:
- If you're using the
nanoeditor (the default for many systems): PressCTRL + Xto close, then pressYto confirm the changes, and finally pressEnterto save. - If you're using the
vimeditor: PressEsc, then type:wqand pressEnter.
- If you're using the
-
Verify the Cron Job: To make sure your new cron job has been added, you can list the crontab entries with:
crontab -l
You should see your new command in the list. This will ensure that yt-dlp is updated daily at the specified time.
Note: The exact path to pip3 might differ based on how it was installed and your system setup. The provided path (/usr/local/bin/pip3) is a common one. If pip3 is located elsewhere, you might need to adjust the path in the cron job accordingly. You can find the path using which pip3.
The Open Source Video Platform Solution
| Service | Description | Link |
|---|---|---|
| 🎯 | Professional Support - Direct assistance from core developers | Contact |
| ☁️ | AVideo CDN - High-performance video delivery network | Pricing |
AVideo Platform © 2024 - Self-hosted video streaming platform
Made with ❤️ by WWBN and the open source community