You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the feature or problem you’d like to solve
Is there a need to display a changelog for CLI, potentially via the command line?
Proposed solution
Something like gh --changelog or similar so users can learn more about updates. It is helpful for me in case I need to go back and see when a feature was released or if I missed the marketing material.
This is trickier than I thought. Here are some options and I'm not sure what the best way forward is.
Use a changelog.txt file
This is easy to edit, easy edit for people to find in the repo, and easy for scripts to manipulate. But because we compile to a binary it is hard to get that text into the app via gh changelog. I think the way to do this is to add an extra build step to our makefile and to .goreleaser.yml that will convert the changelog into a go file.
Use a changelog.json file
This is a lot like the changelog.txt but it makes writing scripts to update it a little easier.
Use a changelog.go file
This makes it very easy to display the changelog in gh changelog, but it is less readable by users, and it's harder to write scripts that will directly edit a go file. It is also harder to turn this go file into something we can post in the relase notes on https://github.com/github/homebrew-gh/releases/tag/v0.3.5.
I feel like I've spent too much time thinking about this and there is a very simple solution that eludes me. But I can't figure it out.
As for generating the changelog to use in online release notes, I've spiked something really quick: #199
Now, assuming that we've gotten the GitHub Releases changelog out of the way, the next step is "linking" those notes into the binary so that gh changelog can do something useful. Personally, I don't feel really strongly that we should have a command to display the changelog; perhaps we could simply link to release notes from the man page (gh help). If we really do want to have a special command for this, I second @tierninho's excellent idea that we could simply have it open a URL, rather than having to figure out how to embed release notes into the binary itself. That way, the definite source for a changelog is the GitHub Release itself (which can also be amended by hand post-release if we want to polish up the notes).
i agree with mislav's assessment re: not needing a changelog command. we have gh version which could include a link to a release with a changelog and also link from gh help.
Personally, I don't feel really strongly that we should have a command to display the changelog; perhaps we could simply link to release notes from the man page (gh help)
I can get behind that too. Looking at gh help it is a little crowded. Having the release notes link with the version command makes sense to me since release notes and version are pretty linked. How do people feel about havint gh version output something like...
gh version 0.3.5 (2020-01-06)
Release Notes: https://github.com/github/homebrew-gh/releases/tag/v0.3.5
Activity
probablycorey commentedon Dec 17, 2019
I'm going to split this into three stages.
gh --changelogflag that will show the release notes.tierninho commentedon Dec 19, 2019
Any value or reason to make
gh changelogan alternative cmd, like we did withgh version?probablycorey commentedon Dec 20, 2019
Based on what I've learned, I think using actions to do this is probably more complicated than it needs to be. See #189 for more details.
probablycorey commentedon Jan 6, 2020
This is trickier than I thought. Here are some options and I'm not sure what the best way forward is.
Use a
changelog.txtfileThis is easy to edit, easy edit for people to find in the repo, and easy for scripts to manipulate. But because we compile to a binary it is hard to get that text into the app via
gh changelog. I think the way to do this is to add an extra build step to our makefile and to .goreleaser.yml that will convert the changelog into a go file.Use a
changelog.jsonfileThis is a lot like the
changelog.txtbut it makes writing scripts to update it a little easier.Use a
changelog.gofileThis makes it very easy to display the changelog in
gh changelog, but it is less readable by users, and it's harder to write scripts that will directly edit a go file. It is also harder to turn this go file into something we can post in the relase notes on https://github.com/github/homebrew-gh/releases/tag/v0.3.5.I feel like I've spent too much time thinking about this and there is a very simple solution that eludes me. But I can't figure it out.
tierninho commentedon Jan 6, 2020
Perhaps the easiest solution for now is:
gh changelog= opens browser tab to the new marketing site > release notes pagemislav commentedon Jan 7, 2020
As for generating the changelog to use in online release notes, I've spiked something really quick: #199
Now, assuming that we've gotten the GitHub Releases changelog out of the way, the next step is "linking" those notes into the binary so that
gh changelogcan do something useful. Personally, I don't feel really strongly that we should have a command to display the changelog; perhaps we could simply link to release notes from the man page (gh help). If we really do want to have a special command for this, I second @tierninho's excellent idea that we could simply have it open a URL, rather than having to figure out how to embed release notes into the binary itself. That way, the definite source for a changelog is the GitHub Release itself (which can also be amended by hand post-release if we want to polish up the notes).vilmibm commentedon Jan 7, 2020
i agree with mislav's assessment re: not needing a changelog command. we have
gh versionwhich could include a link to a release with a changelog and also link fromgh help.probablycorey commentedon Jan 7, 2020
I can get behind that too. Looking at
gh helpit is a little crowded. Having the release notes link with the version command makes sense to me since release notes and version are pretty linked. How do people feel about havintgh versionoutput something like...tierninho commentedon Jan 7, 2020
👍 on the idea and in favor of dropping
gh-changelogaltogether we implement thisMerge pull request #111 from github/jg/remove-dir
Create MAKIN-911 PROACTIVE FIRE EMERGENCY RESPONED SYSTEMS