Skip to content

Commit

Permalink
Merge pull request #163 from sapcc/goreleaser
Browse files Browse the repository at this point in the history
  • Loading branch information
SuperSandro2000 authored Oct 11, 2023
2 parents 66c9c6e + 539a13a commit 860e142
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 20 deletions.
File renamed without changes.
10 changes: 5 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## 3.2.0 - 2023-03-03

## Added
### Added

- Support for showing cluster global rate limits.

Expand All @@ -35,26 +35,26 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## 3.1.3 - 2022-12-15

## Added
### Added

- Support for specifying TLS client certificate and key using flags (`--os-cert`/`--os-key`) or
environment variables (`OS_CERT`/`OS_KEY`).

## 3.1.2 - 2022-11-24

## Fixed
### Fixed

- Examples for `domain set` and `project set` commands.

## 3.1.1 - 2022-11-20

## Fixed
### Fixed

- Removed dead code.

## 3.1.0 - 2022-11-20

## Added
### Added

- Add shell completions to Homebrew formula.
- Added detailed examples for `project set` and `domain set` commands.
Expand Down
11 changes: 4 additions & 7 deletions Makefile.maker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ golang:
golangciLint:
createConfig: true

goreleaser:
enabled: true
goReleaser:
# NOTE: this is default behavior but we define this option explicitly for documentation purposes.
# limesctl uses a custom config file which includes Homebrew tap definition.
createConfig: false

githubWorkflow:
ci:
Expand All @@ -38,8 +40,3 @@ renovate:
- talal
- majewsky
- SuperSandro2000

verbatim: |
build/release-info: CHANGELOG.md | build
@if ! hash release-info 2>/dev/null; then printf "\e[1;36m>> Installing release-info...\e[0m\n"; go install github.com/sapcc/go-bits/tools/release-info@latest; fi
release-info $< $(shell git describe --tags --abbrev=0) > $@
44 changes: 36 additions & 8 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,45 @@
# Release Guide

1. Ensure local `master` branch is up to date with `origin/master`.
2. Ensure all checks are passing: `make check`.
3. Update the [`CHANGELOG`](./CHANGELOG.md) as appropriate.
We use [GoReleaser][goreleaser] and GitHub workflows for automating the release
process. Follow the instructions below for creating a new release.

1. Ensure local `master` branch is up to date with `origin/master`:

```sh
git fetch --tags && git pull --tags
```

2. Ensure all checks are passing:

```sh
make check
```

3. Update the [`CHANGELOG`](./CHANGELOG.md).
Make sure that the format is consistent especially the version heading.
We follow [semantic versioning][semver] for our releases.
You can check if the file format is correct by running `make build/release-info` and examining `make build/release-info`.

You can check if the file format is correct by running [`release-info`][release-info] for the new version:

```sh
go install github.com/sapcc/go-bits/tools/release-info@latest
release-info CHANGELOG.md X.Y.Z
```

where `X.Y.Z` is the version that you are planning to release.

4. Commit the updated changelog with message: `Release <version>`
5. Create and push a new Git tag.
Note that tags are prefixed with `v` and the GitHub release workflow is triggered for tags that match the `v[0-9]+.[0-9]+.[0-9]+` [gh-pattern].
A [lightweight tag][lightweight-tags] is sufficient as GoReleaser will update the release description using the release notes generated by [release-info].
5. Create and push a new Git tag:

```sh
git tag vX.Y.Z
git push --tags
```

> [!IMPORTANT]
> Tags are prefixed with `v` and the GitHub release workflow is triggered for tags that match the `v[0-9]+.[0-9]+.[0-9]+` [gh-pattern].

[release-info]: https://github.com/sapcc/go-bits/tree/master/tools/release-info
[lightweight-tags]: https://git-scm.com/book/en/v2/Git-Basics-Tagging#_lightweight_tags
[semver]: https://semver.org/spec/v2.0.0.html
[gh-pattern]: https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#patterns-to-match-branches-and-tags
[goreleaser]: https://github.com/goreleaser/goreleaser

0 comments on commit 860e142

Please sign in to comment.