-
Notifications
You must be signed in to change notification settings - Fork 7.6k
Generate manpages from cobra #915
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
Conversation
|
@mtfurlan Thank you for proposing this; it looks promising! I will give a more thorough review when I find time 🙇 |
|
what's the way to test this? i took a stab but didn't get a result from |
|
@rojobuffalo They're currently split up so every subcommand gets it's own man page cause that's how cobra does it. It's not amazing, but it's better than nothing and it's technically correct. |
vilmibm
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just have one small nitpick change requested.
Otherwise, this is exciting! I agree that what cobra outputs is not ideal but I'm happy with this as a starting point. I just did a test release and installed a .deb and saw that things were in place.
Thank you for this.
|
Two other things I now that I'm looking over this again:
|
eh, I don't have a problem with it. If we determine it's a problem later on we can circle back.
I know next to nothing about homebrew. I did set up linuxbrew so I could ensure that the brew packages were upgrading properly but yeah, someone would have to research how brew packages tend to handle manpages. I think it's ok to start with them only installing automatically on linux (it's an incremental upgrade from not having them at all). |
vilmibm
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thank you much!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good!
We should also amend our Homebrew formula in goreleaser.yml to include the line
man1.install Dir["manpages/*.1"]It has also ocurred to me that we probably want make manpages as part of our release process
|
if someone wants to test out manpage installation via brew on a mac that would be 💖 otherwise I'll find and charge my very unutilized work mac tomorrow and test it |
|
I figured out how to make goreleaser build the makefiles, and that cobra will make the output dir for us and it doesn't need to be in the makefile. |
|
I've tested the release with |
|
thank you for the macos test! i was dreading getting my mbp up and running again haha |
fixes #900
In it's current state the manpages aren't great, but are technically correct, better than nothing, and will be kept up to date.