-
Notifications
You must be signed in to change notification settings - Fork 354
Parse version from changelog
#2251
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
base: master
Are you sure you want to change the base?
Conversation
|
Hello @joelim-work, I was wondering whether I should introduce a completely new |
|
The date simply comes from Line 21 in b653506
The reason for this was so that every time a new release was made, the documentation would be generated, and the date shown in the man page would match the release date. I am not sure how useful this actually is in practice though, since I don't look at the date myself. I'm also a bit unsure about naming the script |
How about this? Asking the user what to do using an interactive menu (quick and dirty implementation)? |
|
The point I was trying to make above is that the script was originally used for generating documentation only, which is why it was called I don't think user input is necessary, the script should simply generate everything. If there are no changes to the source Markdown files then the result should be a no-op. The only edge case is the date that is displayed in the man page, which is set to the date that the script is run. IMO the date is not that important compared to the version of I'm also not a fan of using different mechanisms for handling Now going back to the original issue #2234, it looks like you just want to be able to distinguish between release builds and custom builds. But this can be solved just by modifying At this point I'm not sure which issue you're trying to solve, is it to improve the |
|
Sorry, I didn't mean to close the PR, was an accidental mouse slip from me. |
Alright, got it.
I thought of this as well. I did not do it as introducing a
This is debatable, however I'd rather have
Embedding
Making the changelog viewable is a nice side-effect of solving the version parsing this way. This is already possible, however not really convenient. I did this by looking for |
I also haven't seen any tools that provide a
I understand that you are trying to compare versions in order to dynamically enable certain options that may or may not be available. But using a future version that is unreleased ( Bumping to the next unreleased version is also not reliable for checking if a feature exists or not. Consider the following hypothetical git history: If the version string is set to If you just wanted to hide errors for possibly non-existent features, I guess another idea is to just clear them using # unreleased features
set feature1 true
set feature2 true
echo
# everything else
set drawbox
set hidden
I must admit that I do sometimes change my mind and go back on what I might have said previously. The reason for this is simply because I will not know everything about a problem before having to think of a solution, and sometimes what I learn about the problem later on affects my judgment. For this particular case, it is definitely possible to embed the contents of the changelog into the application and reference it when printing the version - anything can be implemented if the code is written for it. But the question is, does such a design make sense? Now the changelog is coupled directly to the implementation of the |

-versionflag work for unreleased versions #2234This PR improves version information for unreleased versions.
It achieves this by embedding and parsing
CHANGELOG.md.Before:
After:
It also exposes the changelog as
newswhich makes it possible to create aneovim-inspired command to show the latest changes: