1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
# Configuration for cargo-release (https://github.com/crate-ci/cargo-release).
#
# One-time setup:
# cargo install cargo-release
#
# Cut a release:
# cargo release 0.1.0 # dry run — shows what would happen
# cargo release 0.1.0 --execute # bumps the crate version, rewrites the
# # [Unreleased] section of CHANGELOG.md,
# # commits, tags v0.1.0, pushes, and
# # publishes to crates.io.
# Publish to crates.io on release. Requires a crates.io token configured
# on the maintainer's machine (`cargo login`).
= true
# Tag template: `vX.Y.Z`. Match git-tag conventions and what bioconda
# recipes typically grep for.
= "v{{version}}"
# Commit each released crate's version bump on its own, rather than in one
# consolidated workspace commit. This is what makes `{{version}}` interpolate:
# in the consolidated-commit context cargo-release binds only `{{date}}`, so
# every version variable (`{{version}}`, `{{next_version}}`, `{{prev_version}}`)
# renders as a literal — that is how v0.1.1 landed with the commit message
# "Bump version to {{next_version}}". Only dupblaster is ever released here
# (bench-compare sets `publish = false`), so "per-crate" still means one commit.
= false
# Match the commit-message style used for past version bumps.
= "Bump version to {{version}}"
# Rewrite CHANGELOG.md at release time:
# 1. Replace `## [Unreleased]` with `## [Unreleased]\n\n## [X.Y.Z] - YYYY-MM-DD`
# so the previous section is renamed and a fresh empty Unreleased
# section is left at the top for future work.
# 2. Update the compare URL at the bottom of the file: the old
# `[Unreleased]: .../compare/HEAD` becomes
# `[Unreleased]: .../compare/vX.Y.Z...HEAD`, and a new
# `[X.Y.Z]: .../compare/vP.R.E...vX.Y.Z` line is appended.
#
# `prerelease = true` allows these to be no-ops on a fresh repo where
# the previous tag doesn't exist yet (avoids "previous version not
# found" errors before the first release).
= [
{ = "CHANGELOG.md", = "## \\[Unreleased\\]", = "## [Unreleased]\n\n## [{{version}}] - {{date}}", = 1 },
# Regex matches the current `[Unreleased]:` compare link whatever it points
# to (`/compare/HEAD` on the first release, `/compare/vX.Y.Z...HEAD` after),
# so this works for every release, not just the first.
{ = "CHANGELOG.md", = "\\[Unreleased\\]: https://github.com/fulcrumgenomics/dupblaster/compare/.+", = "[Unreleased]: https://github.com/fulcrumgenomics/dupblaster/compare/v{{version}}...HEAD\n[{{version}}]: https://github.com/fulcrumgenomics/dupblaster/releases/tag/v{{version}}", = 1 },
]