Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] `--write-sub -o -` writes subtitle to a file named - #25344

Open
NightMachinary opened this issue May 21, 2020 · 3 comments
Open

[BUG] `--write-sub -o -` writes subtitle to a file named - #25344

NightMachinary opened this issue May 21, 2020 · 3 comments

Comments

@NightMachinary
Copy link

@NightMachinary NightMachinary commented May 21, 2020

Checklist

  • I'm reporting a broken site support issue
  • I've verified that I'm running youtube-dl version 2020.05.08
  • I've checked that all provided URLs are alive and playable in a browser
  • I've checked that all URLs and arguments with special characters are properly quoted or escaped
  • I've searched the bugtracker for similar bug reports including closed ones
  • I've read bugs section in FAQ

Verbose log

Description

--write-sub -o - writes subtitle to a file named -. It should use the video's name or accept a name with a new cli option.

@rafinetiz
Copy link

@rafinetiz rafinetiz commented May 22, 2020

you can't write the output to file named -, as i know, when you pass - to -o option, the output will be written to STDOUT.

and if you mean you want to write subtitle to different name, i think this is not a bug but a feature request.

@NightMachinary
Copy link
Author

@NightMachinary NightMachinary commented May 22, 2020

@rafinetiz the problem is that the video file is going into stdout, so the subtitle file has nowhere to go.

@jrauhamaa
Copy link

@jrauhamaa jrauhamaa commented May 22, 2020

Same thing seems to happen when format is specified.
$ youtube-dl <url> -o - > video
writes to a file named 'video', while
$ youtube-dl <url> -f <FORMAT> -o - > video
writes the video to '-.mkv'

Somehow the -o - option gets interpreted differently depending on whether format options are provided or not.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.