9

I would like to download auto-generated subtitles with youtube-dl as follows

$ youtube-dl --write-auto-sub \
             --skip-download \
             https://www.youtube.com/watch?v=vbLEf4HR74E

It downloads file The habits of happiness _ Matthieu Ricard-vbLEf4HR74E.en.vtt which is not auto-generated subtitles, it contains the word coke box instead of Coca-Cola tins.

How to download the right file?

Scrooge McDuck
  • 996
  • 1
  • 9
  • 23
xralf
  • 16,149
  • 29
  • 101
  • 149
  • which version do you use? – Jaleks Jun 16 '18 at 21:25
  • @Jaleks 2018.06.14 – xralf Jun 16 '18 at 21:28
  • `youtube-dl **--write-sub** --skip-download _--sub-lang=en_ "https://www.youtube.com/watch?v=vbLEf4HR74E" ` does something looking OK for my version 2017.05.18.1-1. youtube-dl tells me "Couldn't find automatic captions for vbLEf4HR74E" for `--write-auto-sub` – Jaleks Jun 16 '18 at 21:37
  • @Jaleks Your command also doesn't download autogenerated subtitles, but human-translated subtitles instead (with the word "coke box"). You need to [update youtube-dl](https://github.com/rg3/youtube-dl/blob/master/README.md#how-do-i-update-youtube-dl) – xralf Jun 16 '18 at 21:51
  • Different versions - different results. I get "Coca-cola tins"… – Jaleks Jun 16 '18 at 21:53
  • I'm sorry you're right. I should use --write-sub instead of --write-auto-sub. It works now. – xralf Jun 16 '18 at 22:02

1 Answers1

12
youtube-dl --write-sub \
           --skip-download \
           --sub-lang=en \
           "https://www.youtube.com/watch?v=vbLEf4HR74E"

does something looking OK on version 2017.05.18.1-1.

youtube-dl says Couldn't find automatic captions for vbLEf4HR74E with --write-auto-sub but --write-sub with a selected language --sub-lang=en seems to work.

Scrooge McDuck
  • 996
  • 1
  • 9
  • 23
Jaleks
  • 2,499
  • 1
  • 17
  • 34
  • 2
    Yes, sometimes works `--write-sub` and sometimes works `--write-auto-sub` (when human-translated subtitles are missing) – xralf Jun 18 '18 at 19:24