Expand description
Which release a binary is, and how two releases order.
The part crates/kernel/spec/Release.lean specifies this module.
One release is spelled two ways, and this is the only place that
knows both. A pre-alpha git tag reads v0.0.5-Pre-alpha-260912; npm accepts
semver and nothing else, so the same release reaches the registry as
0.0.5-pre.260912. xtask channel converts in order to publish, and
a running binary converts in order to ask the registry which release
is newest. Either conversion written a second time would be a second
answer to “which release is this”.
The order is semver’s own. Putting the date in the pre-release
field ranks 0.0.5-pre.260912 above 0.0.5-pre.260911 and below a
plain 0.0.5, because semver compares dot-separated numeric
identifiers numerically. Deriving Ord over these fields in
declaration order reproduces that rule, so this crate and the
registry sort one pair of releases the same way. A binary that
compared its own bare 0.0.5 against 0.0.5-pre.260912 would read
itself as the newer of the two, which is the reason the date has to
travel with the version rather than beside it.
The maturity is written once. A tag carries it between the
version and the date, -Alpha- today; MATURITY is the one
place it is decided, and the tag, the first line of sprawling status
and the documents render it (kernel D18). The npm spelling keeps
-pre. whatever the maturity, because semver sorts pre-release
identifiers as text and alpha sorts before pre.
No clock and no socket. What the registry currently offers is the caller’s to fetch; this judges only what it is handed (ARCHITECTURE.md paragraph 1).
Structs§
- Release
- One published release of this project, in the form both spellings decode to.
- Version
- A release named by its version number alone, as crates.io names it
(
crates/kernel/spec/Release.lean§8-54-1, kernel D35).
Enums§
- Maturity
- How far this project stands, as every release it cuts names it (kernel D18).
- Release
Verdict - Where one release stands against the newest one published.
Constants§
- AUR_
PACKAGE_ NAME - The package identity shared by the AUR definition and installed-origin reader.
- MATURITY
- The maturity of every release this tree cuts.
Functions§
- aur_
install_ directory - The POSIX directory relative to the installation root, including bundled resources.
- is_
aur_ install - Whether the executable occupies the directory emitted by the AUR packager.
- stands
- Where
minestands against the newest release published. - stands_
on_ crates - Where
minestands against the newest version crates.io offers, judged on the version number alone (kernel D35): crates.io takes one upload per version, so a re-cut that changed only the date never reaches it, and for a binary cargo installed the same version is current. - stands_
on_ versions - Compares Cargo versions when a registry install was compiled without a release tag.