Skip to content

Commit 0624bcc

Browse files
bors-ferrocene[bot]Amanjeev Sethi
andauthored
Merge #70
70: README update with cutting a release r=Hoverbear a=amanjeev Co-authored-by: Amanjeev Sethi <[email protected]>
2 parents 1c3db8a + 8e92535 commit 0624bcc

File tree

3 files changed

+65
-6
lines changed

3 files changed

+65
-6
lines changed

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,12 @@
55

66
All notable changes to this project will be documented in this file.
77

8+
## [Unreleased]
9+
10+
### Added
11+
12+
- Release instructions to README.
13+
814
## [1.2.0] - 2024-11-25
915

1016
### Changed
@@ -67,8 +73,13 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6773
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
6874

6975
[Unreleased]: https://github.com/ferrocene/criticalup/compare/v1.2.0...HEAD
76+
7077
[1.2.0]: https://github.com/ferrocene/criticalup/compare/v1.1.0...v1.2.0
78+
7179
[1.1.0]: https://github.com/ferrocene/criticalup/compare/v1.1.0...v1.0.2
80+
7281
[1.0.2]: https://github.com/ferrocene/criticalup/compare/v1.0.1...v1.0.2
82+
7383
[1.0.1]: https://github.com/ferrocene/criticalup/compare/v1.0.0...v1.0.1
84+
7485
[1.0.0]: https://github.com/ferrocene/criticalup/compare/v1.0.0...v1.0.0-prerelease.1

README.md

Lines changed: 53 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,18 +5,23 @@
55

66
Criticalup is a toolchain manager for [Ferrocene][ferrocene], similar to [`rustup`][rustup].
77

8-
> [!NOTE]
8+
> [!NOTE]
99
>
1010
> For normal usage and binary installation, please consult the [CriticalUp Documentation][criticalup-docs].
1111
12-
# Installing
12+
## Installing
1313

14-
Installation instructions for CriticalUp are included in [each release](https://github.com/ferrocene/criticalup/releases) as well as the [documentation][criticalup-docs].
14+
Installation instructions for CriticalUp are included
15+
in [each release](https://github.com/ferrocene/criticalup/releases) as well as the [documentation][criticalup-docs].
1516

17+
## Development
1618

17-
# Development
19+
CriticalUp only requires a working Rust and C toolchain to build. [Installation instructions][rust-install] for Rust
20+
typically include installing a C toolchain as well.
1821

19-
CriticalUp only requires a working Rust and C toolchain to build. [Installation instructions][rust-install] for Rust typically include installing a C toolchain as well.
22+
### Build
23+
24+
#### Debug
2025

2126
To build a debug version of the development-targeting CriticalUp:
2227

@@ -30,19 +35,62 @@ To build a debug version of the production-targeting CriticalUp:
3035
cargo build -p criticalup
3136
```
3237

38+
#### Release
39+
3340
To build a release version:
3441

3542
```bash
3643
cargo build -p criticalup --release
3744
```
3845

46+
### Test
47+
3948
To test CriticalUp:
4049

4150
```bash
4251
cargo test
4352
```
4453

54+
## Releasing a new version
55+
56+
We use [`cargo-dist`](https://opensource.axo.dev/cargo-dist/book/quickstart/rust.html) to publish releases.
57+
58+
To cut a release:
59+
60+
- `git pull` on the `main` branch for latest changes.
61+
- Create and checkout a new release branch from `main`, use the naming convention - `release/vX.Y.Z`.
62+
Where, `X.Y.Z` is the release version you are trying to release.
63+
- Update the following on the release branch
64+
- [crates/criticalup/Cargo.toml](./crates/criticalup/Cargo.toml): Change `version` to `X.Y.Z`.
65+
- [crates/criticalup-cli/Cargo.toml](./crates/criticalup-cli/Cargo.toml): Change `version` to `X.Y.Z`.
66+
- [crates/criticalup-dev/Cargo.toml](./crates/criticalup-dev/Cargo.toml): Change `version` to `X.Y.Z`.
67+
- [crates/criticalup-cli/tests/snapshots/cli__root__version_flags.snap](./crates/criticalup-cli/tests/snapshots/cli__root__version_flags.snap):
68+
Update this test to match the correct version (`X.Y.Z`).
69+
- [CHANGELOG.md](./CHANGELOG.md): Make `[Unreleased]` the correct version (`[X.Y.Z]`). Add correct links metadata at
70+
the bottom.
71+
- [dist-workspace.toml](./dist-workspace.toml): Change `pr-run-mode = "plan"` to `pr-run-mode = "upload"`.
72+
**Commit this change separately!** (We will need to drop this commit once the PR passes)
73+
- Run `cargo test --workspace` and `cargo clippy --workspace --tests --locked -- -Dwarnings` to make sure there no
74+
failures.
75+
- Commit and push this branch and open a PR against `main`, on GitHub.
76+
- If the full CI test cycle on the PR passes and the reviewer(s) are OK, drop the
77+
[dist-workspace.toml](./dist-workspace.toml) commit from above and push.
78+
- Wait for approval(s) from reviewer(s).
79+
- Once the PR is approved, comment `bors merge` to merge the PR.
80+
- After the PR is merged, checkout `main` branch and update it (`git pull`) with the latest changes.
81+
- Create a tag `git tag 'vX.Y.Z'`.
82+
- Push the tag `git push origin vX.Y.Z`. This should trigger the release build in GitHub Actions and publish the release
83+
on its own.
84+
85+
If the release build fails:
86+
87+
- Revert the changes from `release/vX.Y.Z` and open a PR to be merged to `main`.
88+
- Delete the tag from GitHub.
89+
4590
[criticalup-docs]: https://criticalup.ferrocene.dev/
91+
4692
[rustup]: https://github.com/rust-lang/rustup
93+
4794
[ferrocene]: https://ferrocene.dev/
95+
4896
[rust-install]: https://www.rust-lang.org/tools/install

crates/criticaltrust/src/serde_base64.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ where
2828
{
2929
struct Base64Visitor<T: SerdeBase64>(PhantomData<T>);
3030

31-
impl<'de, T: SerdeBase64> Visitor<'de> for Base64Visitor<T> {
31+
impl<T: SerdeBase64> Visitor<'_> for Base64Visitor<T> {
3232
type Value = T;
3333

3434
fn expecting(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {

0 commit comments

Comments
 (0)