Skip to content
This repository has been archived by the owner on Oct 10, 2023. It is now read-only.

Commit

Permalink
Add binaries to every new release (#237)
Browse files Browse the repository at this point in the history
* Add release yaml to workflows

Signed-off-by: thepetk <thepetk@gmail.com>

* Remove autogeneration of release notes

Signed-off-by: thepetk <thepetk@gmail.com>

* Update readme

Signed-off-by: thepetk <thepetk@gmail.com>

* Update Readme.md

Signed-off-by: thepetk <thepetk@gmail.com>

---------

Signed-off-by: thepetk <thepetk@gmail.com>
  • Loading branch information
thepetk committed Jun 29, 2023
1 parent 4fbb42a commit 15ff51f
Show file tree
Hide file tree
Showing 2 changed files with 67 additions and 1 deletion.
54 changes: 54 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
on:
push:
tags:
- 'v*'

name: Build Release

defaults:
run:
shell: bash

permissions:
contents: write

jobs:
release:
name: Create Release
runs-on: 'ubuntu-latest'
strategy:
matrix:
goosarch:
- 'darwin/amd64'
- 'linux/amd64'
- 'linux/ppc64le'
- 'linux/s390x'
- 'windows/amd64'
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: actions/setup-go@v4
with:
go-version: '1.19.5'
- name: Get OS and arch info
run: |
GOOSARCH=${{matrix.goosarch}}
GOOS=${GOOSARCH%/*}
GOARCH=${GOOSARCH#*/}
BINARY_NAME=alizer-$GOOS-$GOARCH
echo "BINARY_NAME=$BINARY_NAME" >> $GITHUB_ENV
echo "GOOS=$GOOS" >> $GITHUB_ENV
echo "GOARCH=$GOARCH" >> $GITHUB_ENV
- name: Build
run: |
cd go/
go build -o "$BINARY_NAME" -v
- name: Release with Notes and Binaries
uses: softprops/action-gh-release@v1
with:
draft: false
files: go/${{env.BINARY_NAME}}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -160,9 +160,21 @@ For information on getting started, refer to the [CONTRIBUTING instructions](CON

The release process of `alizer` is very straightforward. You can create a new release [here](https://github.com/redhat-developer/alizer/releases/new).

- The _title_ of the release has to be the new version. `Alizer` follows the `{major}.{minor}.{bugfix}` format (e.g `0.1.0`)
- The _title_ of the release has to be the new version. `Alizer` follows the `v{major}.{minor}.{bugfix}` format (e.g `v0.1.0`)
- The _description_ of the release is optional. You may add a description if there were outstanding updates in the project, not mentioned in the issues or PRs of this release.

### Release Binaries
For each release a group of binary files is generated. More detailed we have the following types:
- `linux/amd64`
- `linux/ppc65le`
- `linux/s390x`
- `windows/amd64`
- `darwin/amd64`

In order to download a binary file:
* Go to the release you are interested for `https://github.com/thepetk/alizer/releases/tag/<release-tag>`
* In the **Assets** section you will see the list of generated binaries for the release.

## Feedback & Questions

If you discover an issue please file a bug and we will fix it as soon as possible.
Expand Down

0 comments on commit 15ff51f

Please sign in to comment.