Skip to content

fix: remove flickering from install script spinner animation #3

fix: remove flickering from install script spinner animation

fix: remove flickering from install script spinner animation #3

Workflow file for this run

name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '1.21'
cache: true
- name: Run tests
run: go test -v -race ./...
release:
name: Release
runs-on: ubuntu-latest
needs: test
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '1.21'
cache: true
- name: Get version from tag
id: version
run: echo "VERSION=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Build binaries
run: |
VERSION=${{ steps.version.outputs.VERSION }}
LDFLAGS="-s -w -X main.version=${VERSION}"
# Linux amd64
GOOS=linux GOARCH=amd64 go build -ldflags="${LDFLAGS}" -o dist/haft-linux-amd64 ./cmd/haft
tar -czvf dist/haft-linux-amd64.tar.gz -C dist haft-linux-amd64
# Linux arm64
GOOS=linux GOARCH=arm64 go build -ldflags="${LDFLAGS}" -o dist/haft-linux-arm64 ./cmd/haft
tar -czvf dist/haft-linux-arm64.tar.gz -C dist haft-linux-arm64
# macOS amd64
GOOS=darwin GOARCH=amd64 go build -ldflags="${LDFLAGS}" -o dist/haft-darwin-amd64 ./cmd/haft
tar -czvf dist/haft-darwin-amd64.tar.gz -C dist haft-darwin-amd64
# macOS arm64
GOOS=darwin GOARCH=arm64 go build -ldflags="${LDFLAGS}" -o dist/haft-darwin-arm64 ./cmd/haft
tar -czvf dist/haft-darwin-arm64.tar.gz -C dist haft-darwin-arm64
# Windows amd64
GOOS=windows GOARCH=amd64 go build -ldflags="${LDFLAGS}" -o dist/haft-windows-amd64.exe ./cmd/haft
zip -j dist/haft-windows-amd64.zip dist/haft-windows-amd64.exe
- name: Generate checksums
run: |
cd dist
sha256sum *.tar.gz *.zip > checksums.txt
- name: Create Release
uses: softprops/action-gh-release@v1
with:
name: ${{ steps.version.outputs.VERSION }}
draft: false
prerelease: ${{ contains(steps.version.outputs.VERSION, '-') }}
generate_release_notes: true
files: |
dist/haft-linux-amd64.tar.gz
dist/haft-linux-arm64.tar.gz
dist/haft-darwin-amd64.tar.gz
dist/haft-darwin-arm64.tar.gz
dist/haft-windows-amd64.zip
dist/checksums.txt
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}