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
1 change: 1 addition & 0 deletions COMPAT.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

| zig-common | Zig | tools built on it |
|---|---|---|
| 0.11.0 | 0.17.1 | eb-keep-logs and eessi-arch-guard on their next releases (`syslog`: the RFC 5424 and journald emitter each carried a copy of); eb-keep-logs builds against it in CI |
| 0.10.0 | 0.17.1 | eessi-arch-guard and eb-staged-rebuild (`fsx.mkdtemp`, `fsx.normPath`, `fsx.absPath`); eb-keep-logs builds against it in CI |
| 0.9.0 | 0.17.1 | eessi-arch-guard on its next release (proc.killGroup); eb-keep-logs builds against it in CI |
| 0.8.1 | 0.17.1 | eb-staged-rebuild, eb-keep-logs and eessi-arch-guard on their next releases (umask read without changing it, std names without deprecated aliases) |
Expand Down
18 changes: 12 additions & 6 deletions RELEASING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,17 @@

A release is an annotated tag `vX.Y.Z` on `main`; there are no binaries.

1. `.version` in `build.zig.zon` names the new version.
2. CI on `main` is green, including the `tools` job that builds every tool
1. Branch from `main`: `git switch -c chore/release-X.Y.Z origin/main`.
2. `COMPAT.md` gets a row for the version: the Zig version and the tool
versions built on it. Commit it with a `changelog.d` fragment.
3. `cog bump --minor` (or `--patch`, `--major`, `--version X.Y.Z`). The hooks
of `cog.toml` set `.version` in `build.zig.zon` and refuse a version with
no `COMPAT.md` row; cog commits `chore(version): vX.Y.Z` and creates the
tag on that commit.
4. Push the branch, open the pull request, and merge it with a merge commit
once CI is green, including the `tools` job that builds every tool
against this commit.
3. `COMPAT.md` has a row for the version: the Zig version and the tool
versions built on it.
4. Tag and push: `git tag -a vX.Y.Z -m vX.Y.Z && git push origin vX.Y.Z`.
5. Each tool moves to the tag in a commit of its own:
5. Sign and push the tag:
`git tag -s -f vX.Y.Z -m vX.Y.Z 'vX.Y.Z^{}' && git push origin vX.Y.Z`.
6. Each tool moves to the tag in a commit of its own:
`zig fetch --save git+https://github.com/stackhands/zig-common#vX.Y.Z`.
2 changes: 1 addition & 1 deletion build.zig.zon
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.{
.name = .zig_common,
.version = "0.10.0",
.version = "0.11.0",
.fingerprint = 0xa9bcabd6798f1690,
.minimum_zig_version = "0.17.1",
.dependencies = .{},
Expand Down
1 change: 1 addition & 0 deletions changelog.d/+release-0.11.0.misc.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Prepare `zig-common` `0.11.0` in `COMPAT.md` for callers adopting `syslog`. A release is now `cog bump` on a release branch: `cog.toml` sets the version in `build.zig.zon` and refuses a version without a `COMPAT.md` row.
13 changes: 13 additions & 0 deletions cog.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# `cog bump --minor` (or --patch, --major, --version X.Y.Z) on a release branch
# sets the version in build.zig.zon, commits `chore(version): vX.Y.Z` and
# creates the tag on that commit. RELEASING.md has the steps around it.
tag_prefix = "v"
ignore_merge_commits = true
# CHANGELOG.md is built by towncrier from changelog.d/.
disable_changelog = true
branch_whitelist = ["chore/release-*"]

pre_bump_hooks = [
"sed -i 's/^\\( *\\.version = \\)\"[0-9.]*\",$/\\1\"{{version}}\",/' build.zig.zon",
"grep -q '^| {{version}} |' COMPAT.md",
]
Loading