Skip to content

Commit bbb7a2f

Browse files
authored
doc/release.md: Document release process (#373)
Signed-off-by: Max Inden <[email protected]>
1 parent aeff6bf commit bbb7a2f

File tree

1 file changed

+63
-0
lines changed

1 file changed

+63
-0
lines changed

docs/release.md

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Release process
2+
3+
## Crate prometheus
4+
5+
1. Create pull request with bumped `version` in `Cargo.toml` and updated `CHANGELOG.md`.
6+
7+
2. Once merged clean your local environment.
8+
9+
```bash
10+
cargo clean
11+
git clean -fd
12+
```
13+
14+
3. Tag the release.
15+
16+
```bash
17+
tag="v$(sed -En 's/^version = \"(.*)\"$/\1/p' Cargo.toml)"
18+
git tag -s "${tag}" -m "${tag}"
19+
```
20+
21+
4. Publish the release.
22+
23+
```bash
24+
cargo publish
25+
```
26+
27+
5. Push the tag.
28+
29+
```bash
30+
git push origin $tag
31+
```
32+
33+
## Crate prometheus-static-metric
34+
35+
1. Create pull request with bumped `version` in `static-metric/Cargo.toml` and updated `static-metric/CHANGELOG.md`.
36+
37+
2. Once merged clean your local environment.
38+
39+
```bash
40+
cd static-metric
41+
cargo clean
42+
git clean -fd
43+
```
44+
45+
3. Tag the release.
46+
47+
```bash
48+
tag="$(sed -En 's/^name = \"(.*)\"$/\1/p' Cargo.toml | head -n 1)-v$(sed -En 's/^version = \"(.*)\"$/\1/p' Cargo.toml)"
49+
git tag -s "${tag}" -m "${tag}"
50+
```
51+
52+
4. Publish the release.
53+
54+
```bash
55+
cargo publish
56+
```
57+
58+
5. Push the tag.
59+
60+
```bash
61+
git push origin $tag
62+
```
63+

0 commit comments

Comments
 (0)