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

json output? #148

Open
jackmac92 opened this issue Feb 3, 2023 · 1 comment
Open

json output? #148

jackmac92 opened this issue Feb 3, 2023 · 1 comment

Comments

@jackmac92
Copy link

Hey I'd like to use go-chromecast for scripting, e.g. get the current author/title of the playing video non-interactively

And extracting from json with jq would make my life much simpler.

I'm not familiar with the codebase, but if you don't have any known gotchas/concerns I'd like to take a stab at a PR with a flag for output format

@vishen
Copy link
Owner

vishen commented Feb 4, 2023

Hey! That sounds like a good idea; I can't think of any immediate issues that might be of concern. There is a JSON version of the output in https://github.com/vishen/go-chromecast/blob/master/http/handlers.go for the HTTP responses, but I don't know how reusable that is (don't worry about unifying them either).

Not sure the best approach for this, so happy with whatever you come up with! It might require reworking all the output from cmd/ folder, but happy to have a more standardised approach to do this.

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