0

When I type

sudo apt youtube-dl -U 

I get this:

E: Command line option 'U' [from -U] is not understood in combination with the other options.

so I tried pip install --upgrade youtube-dl

and I get: Command 'pip' not found

guntbert
  • 13,134

2 Answers2

2

That's the wrong command, and anyhow the version in the Ubuntu repos (installable through apt) does not receive updates very frequently and is many versions behind. Try removing the version you have installed now and following the guidance on the youtube-dl downloads page.

sudo curl -L https://yt-dl.org/downloads/latest/youtube-dl -o /usr/local/bin/youtube-dl && sudo chmod a+rx /usr/local/bin/youtube-dl

Now when you want to update you don't need apt, just use sudo youtube-dl -U (or use the longer-form --update in place of -U as Hugo already posted).

If you prefer not to use sudo, try installing with pip to your home directory instead with pip install --user youtube_dl and then update regularly with pip install --upgrade --user youtube_dl.

Tom Brossman
  • 13,111
1

If you have Youtube-dl installed then you should be able to run it's own updater.

sudo youtube-dl --update
Baa
  • 3,452