Merge branch 'main' into version-0.2 #34
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release Chemotion CLI | |
on: | |
push: | |
tags: | |
- "*" | |
jobs: | |
build-release-binary: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: "go.mod" | |
- name: Build Go for all OSes | |
run: | | |
cp payload/docker-compose.yml . | |
cp payload/backup.sh . | |
go mod verify | |
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags="-X github.com/${{ github.repository }}/cli.versionCLI=${{ github.ref_name }}" -o chemCLI | |
CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build -ldflags="-X github.com/${{ github.repository }}/cli.versionCLI=${{ github.ref_name }}" -o chemCLI.arm.osx | |
CGO_ENABLED=0 GOOS=darwin GOARCH=amd64 go build -ldflags="-X github.com/${{ github.repository }}/cli.versionCLI=${{ github.ref_name }}" -o chemCLI.amd.osx | |
CGO_ENABLED=0 GOOS=windows GOARCH=amd64 go build -ldflags="-X github.com/${{ github.repository }}/cli.versionCLI=${{ github.ref_name }}" -o chemCLI.exe | |
- name: Release Binaries | |
uses: softprops/action-gh-release@v1 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
files: | | |
chemCLI | |
chemCLI.arm.osx | |
chemCLI.amd.osx | |
chemCLI.exe | |
docker-compose.yml | |
backup.sh | |
token: "${{ secrets.GITHUB_TOKEN }}" |