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
Include more information on updating versions and workspace publishing (#7192)
`cargo workspaces publish --from-git` works quite well and we should
emphasize it more.
Also included substeps for version updating around dependency updates
that ought to avoid problems like
#7191.
---------
Co-authored-by: Robert Bastian <4706271+robertbastian@users.noreply.github.com>
Copy file name to clipboardExpand all lines: documents/process/release.md
+45-28Lines changed: 45 additions & 28 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -32,39 +32,54 @@ This is a checklist of things that should be done in the weeks leading to the re
32
32
*[ ] Verify that `ffi/capi` depends on a released (not Git) version of Diplomat. Get it published (ask manishearth or sffc) otherwise.
33
33
*[ ] Get all contributors to complete the changelog (see below)
34
34
*[ ] Draft the text for the GitHub release and circulate to the WG at least 18 hours in advance of the release, but ideally sooner. This text will be sent to GitHub subscribers and can also be used for the mailing list email and blog post.
35
+
*[ ] Consider making earlier drafts of the changelog (see below), noting a Git commit that the changelog is accurate up to.
35
36
36
37
## Release steps
37
38
38
39
Once the release checklist is complete, the assigned release driver will perform the following steps, in order:
39
40
40
-
* Land the changelog (see below)
41
-
* Note: Do this _before_ tagging the release so that it is included in the tag
42
-
* Remove all `-dev` prelease tags from `Cargo.toml`s
43
-
* Go through the prerelease checklist again, ensuring that no problems were reintroduced in the PRs that landed since the opening of the checklist. (Things like doc prettification will likely need to be rerun!)
44
-
* Release utils (see section below). Get the version bumps reviewed and checked in before releasing.
45
-
* Update ICU4X package versions as needed. Most of this can be done by updating `workspace.package` in the root `Cargo.toml` and the `workspace.dependencies` entries there. Some `icu_*` crates do not follow the ICU4X versioning scheme like `icu_codepointtrie_builder` or experimental crates.
46
-
* Get this reviewed and checked in before continuing
47
-
* Publish each `icu_*` crate
48
-
* Use `cargo workspaces publish --from-git` to automatically publish the crates in the correct order if you would like
49
-
* Add `icu4x-release` group as owners to each new component you're publishing
50
-
*`cargo owner -a github:unicode-org:icu4x-release`
51
-
*[Tag the Release](https://github.com/unicode-org/icu4x/releases) with the text drafted above
52
-
* Update and publish FFI packages
53
-
* Dart
54
-
* update version in `ffi/dart/pubspec.yaml`
55
-
* update the artifacts tag in `ffi/dart/lib/src/hook_helpers/version.dart` to the tag created above
56
-
* get this checked in, then `cd ffi/dart && dart pub publish`
57
-
* JS
58
-
* update version in `icu4x/ffi/npm/package.json`
59
-
* get this checked in, then `cd ffi/npm && npm publish`
60
-
* Create a branch named `release/x.y` including the release tag and FFI commits and push it to the upstream
61
-
* Update the website
62
-
* In the `icu4x-docs` repo, run `node tools/github-to-astro.ts` and follow the instructions
63
-
* Announce the release to public
64
-
* (All releases) Send an email to [icu4x-announce](https://groups.google.com/u/0/a/unicode.org/g/icu4x-announce)
65
-
* (All releases) Blog post on Unicode blog (email Unicode Edcom)
66
-
* (All releases) Update https://www.unicode.org/releases/ (email Ken Whistler)
67
-
* (Major releases only) Submit to This Week In Rust
41
+
*[ ] Land the changelog (see below)
42
+
*[ ] Go through the prerelease checklist again, ensuring that no problems were reintroduced in the PRs that landed since the opening of the checklist. (Things like doc prettification will likely need to be rerun!)
43
+
*[ ] Prepare a PR with updated versions
44
+
*[ ] Remove all `-dev` prelease tags from `Cargo.toml`s
45
+
*[ ] Update all ICU4X crate versions
46
+
*[ ] Update the workspace version to the new version
47
+
*[ ] Some `icu_*` crates do not follow the ICU4X versioning scheme: `icu_codepointtrie_builder`, `icu_pattern`, and `icu_experimental`. Be sure to give them an appropriate version based on the changelog. Major releases are always paired with a `0.x.0` release of `icu_experimental`.
48
+
*[ ] Find all ICU4X component/provider crates that have an overridden version in their `Cargo.toml` and reset it to `version.workspace = true`.
49
+
*[ ] Update all ICU4X `~` dependencies in the toplevel `Cargo.toml`'s `workspace.dependencies`.
50
+
*[ ] Update `icu_locale_core`, `icu_provider`, and `icu_pattern`'s non-`~` dependency in `Cargo.toml`'s `workspace.dependencies`
51
+
* Note: These are in a different section and easy to miss!
52
+
*[ ] Update all relevant utils versions
53
+
*[ ] The changelog should already mention the new versions of each util crate that needs to be published. Use those, and double-check that they are accurate.
54
+
*[ ] For utils that have had substantiative changes (new APIs, etc), update them in `workspace.dependencies`. When unsure, just update.
55
+
*[ ] Get this PR reviewed and checked in.
56
+
*[ ] Perform the release.
57
+
* The best way to do this is to use `cargo workspaces publish --from-git --no-remove-dev-deps`.
58
+
* If the release fails at some point and needs a fix, make a PR for the fix and get it merged. You *may* bypass requirements if necessary, but prefer to wait for most CI and an approval.
59
+
*`cargo publish` does not like cyclic dev-deps and [will fail](https://github.com/rust-lang/cargo/issues/4242) on some crates.
60
+
*`cargo workspaces publish` will automatically edit out dev-deps to handle this. Unfortunately, it [dirties the tree](https://github.com/pksunkara/cargo-workspaces/issues/202) when it does this. Hopefully that issue is fixed.
61
+
* If not, you can instead perform a release by running `cargo publish` on individual folders (going back to `cargo workspaces publish` after the problematic crate is published)
62
+
* When required to remove a dev-dependency, make a commit that replaces it with a path dependency, and then `cargo publish` from the clean git tree.
63
+
* Be sure to push such commits to `main` (you may need to temporarily change branch protection to do so: do not change the ruleset, just remove the default branch from our branch protection ruleset).
64
+
* It is very important to only publish from commits that are reachable from `main` (or other repo branches). It is less important to ensure that the publishes are not "dirty", but it is ideal to try and maintain that.
65
+
*[ ] Add the `icu4x-release` group as owners to each brand new crate that was published
66
+
*`cargo owner -a github:unicode-org:icu4x-release`
67
+
*[ ][Tag the Release](https://github.com/unicode-org/icu4x/releases) with the text drafted above
68
+
*[ ] Update and publish FFI packages
69
+
*[ ] Dart
70
+
*[ ] update version in `ffi/dart/pubspec.yaml`
71
+
*[ ] update the artifacts tag in `ffi/dart/lib/src/hook_helpers/version.dart` to the tag created above, and run `regenerate_hashes.dart`
72
+
*[ ] get this checked in, then `cd ffi/dart && dart pub publish`
73
+
*[ ] JS
74
+
*[ ] update version in `icu4x/ffi/npm/package.json`
75
+
*[ ] get this checked in, then `cd ffi/npm && npm publish`
76
+
*[ ] Create a branch named `release/x.y` including the release tag and FFI commits and push it to the upstream
77
+
*[ ] Update the website
78
+
*[ ] In the `icu4x-docs` repo, run `node tools/github-to-astro.ts` and follow the instructions
79
+
*[ ] Announce the release to public
80
+
*[ ] (All releases) Blog post on Unicode blog (email Unicode Edcom)
81
+
*[ ] (All releases) Update https://www.unicode.org/releases/ (email Ken Whistler)
82
+
*[ ] (Major releases only) Submit to This Week In Rust
68
83
* Keep the main branch relatively stable for 7-14 days following the release to make things easier in case a patch release is needed.
69
84
* It's okay to land smaller or incremental changes, but avoid breaking changes during this period.
70
85
@@ -108,6 +123,8 @@ This can all be done in a separate PR to chunk out the work but there should be
108
123
109
124
In general, the *Unreleased* section of the changelog should be updated with each changelog-worthy PR. However, as this might be forgotten, before a release you should ping all major contributors, and ask them to complete their parts of the changelog. Before the release, rename the *Unreleased* section to the appropriate version.
110
125
126
+
When making a release, it is important to include version changes for all util and other non-ICU4X-versioned crates. If a util crate is not changed, it should have an entry saying `utilname: No change`
127
+
111
128
Out-of-cycle changelogs should use a single entry for each individual crate released, e.g. something like this:
0 commit comments