Skip to content

Fix workflow version detection: add fallback for non-tag triggers #35

Fix workflow version detection: add fallback for non-tag triggers

Fix workflow version detection: add fallback for non-tag triggers #35

Workflow file for this run

name: CI Build and Test
on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]
jobs:
build:
name: Build ${{ matrix.platform }}
runs-on: ubuntu-latest
strategy:
matrix:
include:
- platform: linux
goos: linux
goarch: amd64
- platform: windows
goos: windows
goarch: amd64
- platform: macos
goos: darwin
goarch: amd64
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.21'
- name: Build binary
env:
GOOS: ${{ matrix.goos }}
GOARCH: ${{ matrix.goarch }}
run: |
go mod tidy
go build -o terminusai-${{ matrix.platform }} ./cmd/terminusai
- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: terminusai-${{ matrix.platform }}
path: terminusai-${{ matrix.platform }}*