Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 16 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
name: Release

on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+"

jobs:
publish:
permissions:
id-token: write
contents: read
uses: fastly/devex-reusable-workflows/.github/workflows/publish-rust-crates-io-v1.yml@main
with:
crate_name: esi
expected_version: ${{ github.ref_name }}
47 changes: 47 additions & 0 deletions RELEASING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Releasing

1. **Create a release branch**:

```sh
git checkout main
git pull
git checkout -b release/vX.Y.Z
```

2. **Update the version** in [Cargo.toml](Cargo.toml) under `[workspace.package]`:

```toml
[workspace.package]
version = "X.Y.Z"
```

3. **Regenerate the lockfile**:

```sh
cargo generate-lockfile
```

4. **Commit and push the version bump**:

```sh
git add Cargo.toml Cargo.lock
git commit -m "Release vX.Y.Z"
git push -u origin release/vX.Y.Z
```

5. **Open a pull request** into `main` and get it merged.

6. **Tag the release from `main`**:

```sh
git checkout main
git pull
git tag vX.Y.Z
git push origin vX.Y.Z
```

The tag must match the pattern `vX.Y.Z` and the version in `Cargo.toml`.

7. **Monitor the release**. The [Release workflow](.github/workflows/release.yml) will automatically verify the tag matches the crate version and publish to [crates.io](https://crates.io/crates/esi).

You can follow progress in the **Actions** tab of the repository.
Loading