Files
articulate-parser/.github/workflows/release.yml
2025-05-24 18:13:05 +02:00

48 lines
1.2 KiB
YAML

name: Release
on:
push:
tags:
- 'v*'
permissions:
contents: write
jobs:
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.21.x
- name: Run tests
run: go test -v ./...
- name: Build binaries
run: |
# Build for different platforms
GOOS=windows GOARCH=amd64 go build -o articulate-parser-windows-amd64.exe main.go
GOOS=linux GOARCH=amd64 go build -o articulate-parser-linux-amd64 main.go
GOOS=darwin GOARCH=amd64 go build -o articulate-parser-darwin-amd64 main.go
GOOS=darwin GOARCH=arm64 go build -o articulate-parser-darwin-arm64 main.go
- name: Create Release
uses: softprops/action-gh-release@v1
with:
files: |
articulate-parser-windows-amd64.exe
articulate-parser-linux-amd64
articulate-parser-darwin-amd64
articulate-parser-darwin-arm64
generate_release_notes: true
draft: false
prerelease: false
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}