Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
best way to check if update is available (?) #8114
Comments
|
You may want to have at look at http://rg3.github.io/youtube-dl/update/versions.json and http://rg3.github.io/youtube-dl/update/LATEST_VERSION. These files are used internally for |
|
Good, thanks! |
Hi,
I have incorporated youtube-dl in another program, and I just finished implementing youtube-dl automatic updating as the said program loads. It's working, but the problem is that I'm not sure if my strategy was the best one. What the program currently does is access youtube-dl Download page (https://rg3.github.io/youtube-dl/download.html) and then grab the MD5 hash there and compare against the hash of the currently installed version, and if the hash differs then it updates youtube-dl. But I guess this may not be so good for maintainability, since the page source may be modified anytime. I know I could simply always call
sudo youtube-dl -U, but I prefer to only use the update command if necessary, because of performance (the program is for the Raspberry Pi). So, what do you think? Is there a better way to do it?Thanks!