Uh oh!
There was an error while loading. Please reload this page.
Autoupdate man page rev/date info upon git-archive - #34254
Conversation
rust-highfive
commented
Jun 13, 2016
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @nikomatsakis (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
This didn't seems good enough. A released version of rustc should not use a hash rev I think. Maybe something like |
sanmai-NL
commented
Jun 13, 2016
@reeze: suggestion how to do that? |
There seems no way to auto update the version. but I think we could use a shell to get the current version when trying to generate |
sanmai-NL
commented
Jun 13, 2016
|
hanna-kruppe
commented
Jun 13, 2016
The version number is set in the makefiles (specifically Beyond the scope of this PR, the state of the man page has bothered me any time I run across it. It needs some love. Putting the current version in there is a good start: it was definitely updated since 1.2. Additionally it could also use an audit (if all information in there is still accurate) and update (it's likely missing stuff). |
brson
commented
Jun 20, 2016
To get version numbers in our releases the template will need to be filled in by our build system - the tarballs produced by git and published by github are incomplete and not used for any purpose. The general outline of how to do this would be:
The version number is in mk/main.mk as CFG_RELEASE. The date is not, though perhaps we can just change the manfiles to not include the date. |
brson
commented
Jun 20, 2016
nikomatsakis
commented
Jun 22, 2016
r? @brson (bot must have missed this) |
brson
commented
Jul 11, 2016
Triage: my previous comments still stand. The approach here needs to be elaborated further. |
sanmai-NL
commented
Aug 4, 2016
bors
commented
Aug 6, 2016
☔ The latest upstream changes (presumably #35407) made this pull request unmergeable. Please resolve the merge conflicts. |
brson
commented
Aug 9, 2016
@sanmai-NL Using |
sanmai-NL
commented
Aug 10, 2016
@brson: I'm weighing the options a bit before proceeding. What about using some very small standard CPython 2/3 code? I have some code ready for placeholder substitution (fully using their standard library). Advantage would be a reduced platform dependency compared to |
brson
commented
Aug 11, 2016
@sanmai-NL I'm fine with Python 2. The script would go in |
brson
commented
Aug 11, 2016
With python you have to be careful to invoke the correct one using the |
alexcrichton
commented
Sep 9, 2016
Closing due to inactivity, but feel free to resubmit with a rebase! |
See #25689, in particular this comment
r? @brson
This PR ensures that version-related references in man pages coming with ‘non-working copies’ of the source tree are kept in sync automatically. For copies created with
git archive, including tagged releases (as probably consumed by packagers), the bottom line of the man pages forrustcandrustdocwill automatically read something like inman:Instead of (at Rust 1.9.0):
This solution isn't dependent on manual creation of man pages; that can be reconsidered and this trick can be reused or replaced with whatever future means of autoproduction of man pages. In my view, being precise and current in docs also encourages keeping them current, and increases user confidence that they are indeed reliable and current.
A limitation of the solution is that it doesn't translate the git revision and date to some more readily understood ‘discrete’ tag, such as a version triple. This is AFAICT only possible when you bundle such documentation as an extra release artifact built and added automatically upon tagging. I've done that before for another project, but that must be agreed on first ...