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

Need to escape curly braces when passing {status} #94

Closed
Poorchop opened this issue May 24, 2015 · 3 comments
Closed

Need to escape curly braces when passing {status} #94

Poorchop opened this issue May 24, 2015 · 3 comments

Comments

@Poorchop
Copy link

If a stream title has curly brackets in it, they need to be escaped at least when passing the title to mpv. I wasn't sure how you would want to handle this - I was thinking of just parsing the title for {} and escaping them, but since this might just be a problem with mpv, then it maybe there should first be a check for the default player, which could get more complicated. Or maybe it should just be parsed and escaped as necessary only when {status} is passed as a custom player arg.

To escape the curly brackets, just double them. Example: {random title} -> {{random title}}

@bastimeyer
Copy link
Member

Why would the curly brackets need to be escaped?
This should actually work fine:
mpv --title "{foo} {bar}" /path/to/file

These are the chars which are being escaped right now.

@Poorchop
Copy link
Author

This is actually a livestreamer issue, not an mpv issue. In your livestreamerrc, try player-args=--title="{Livestreamer}" {filename} and you will get a KeyError. If you change it to {{Livestreamer}} instead, then the stream will launch with the expected title of "{Livestreamer}".

@bastimeyer
Copy link
Member

Ok, I see, thank you...

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

No branches or pull requests

2 participants