-
-
Notifications
You must be signed in to change notification settings - Fork 10.8k
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
info: add requires_sudo? and --machine-readable #8819
Conversation
- requires_sudo reports whether we can detect that the cask install will need sudo privileges - the --machine-readable option for `brew cask info` changes the output format to JSON, which is more suitable for parsing from external tools I didn't attempt to include artifact details in the JSON output just yet, since the first goal of this feature is just to tell puppet-brewcask (in boxen) whether it need sudo for a given Cask. refs #8817
A note on |
Oh hey - thanks for the pointer to that conversation; I had missed it. Unlike the linked example, to me this does feel like more of a true modifier to the Does it strike you more as something needing a fresh top-level verb? |
👍 I was thinking that json may not be the best format if/when people start parsing it with standard shell tools like |
Not necessarily. I linked to it because it seemed relevant to the conversation, but I have no strong opinion on the subject either way.
Agreed. |
I hear you there, and I did give it some thought before deciding on JSON. The trouble is that there's not really a standard "awk-friendly" data format, whereas JSON is becoming more and more widely used for data transport between tools. Personally I've found in the last year or so All that being said, I see there could be a good case for us to add an additional awk/grep friendly output format - so how about I make room for that possibility by switching to the |
👍 |
Regarding the "awk-friendly" data format, I think we could be inspired by vagrant: |
+1. JSON support is a great thing, even if we support other formats later. The default text format of |
👍 Working with Boxen to install Vagrant and VirtualBox runs into this same issue. This work is foundational in making that integration smoother. Excited for when this hits. |
Thank you for this. Adding |
Is there anything we can do to get this PR completed/merged? Asking for a Boxen user 😆 |
Anyone else is welcome to pick this up. For now - closing it to reduce noise on the repo. |
install will need sudo privileges
--machine-readable
option forbrew cask info
changes theoutput format to JSON, which is more suitable for parsing from
external tools
I didn't attempt to include artifact details in the JSON output just
yet, since the first goal of this feature is just to tell
puppet-brewcask (in boxen) whether it need sudo for a given Cask.
refs #8817