diff --git a/.github/workflows/go.yml b/.github/workflows/go.yml index c291469..e25dd26 100644 --- a/.github/workflows/go.yml +++ b/.github/workflows/go.yml @@ -3,6 +3,7 @@ name: Go on: push: branches: [ main ] + tags: [ v** ] pull_request: branches: [ main ] workflow_dispatch: @@ -37,3 +38,9 @@ jobs: name: binaries path: | bin/ + + - name: Release + uses: softprops/action-gh-release@v1 + if: startsWith(github.ref, 'refs/tags/') + with: + files: bin/ diff --git a/.gitignore b/.gitignore index c5e82d7..ba077a4 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1 @@ -bin \ No newline at end of file +bin diff --git a/RELEASING.md b/RELEASING.md new file mode 100644 index 0000000..3d7f2b9 --- /dev/null +++ b/RELEASING.md @@ -0,0 +1,13 @@ +# How to release a new version + +- In the github.com ui [Release page](https://github.com/IBM/idemix/releases) click on _'Draft a new release'_ +- Select _'Choose a tag'_ and enter a new tag of the format `v0.0.3` or whatever the next number should be + - note the action workflow later is expecting the tag to start with a 'v' + - this balances some degree of consistency but with flexability to create tags say `v1.0.0-beta-2` + - Please see the [Go notes on module versions](https://go.dev/doc/modules/version-numbers) for more information + - Enter a title - typically something like `Idemix v0.0.3` but no requirements +- The description is free-form - any information on noteable updates can be made. Also the _'generate release notes'_ button is very good at getting a basic changelog. +- Click _'Publish release'_ + +A new release is created, with a tag that can be used in `go get` commands +But also a github action is run to attache the idemix binaries to the release notes automatically.