diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..4252ca1 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,39 @@ +name: Build Go Binaries + +on: + push: + branches: [ main ] + pull_request: + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + matrix: + goos: [linux, windows] + goarch: [amd64, arm, arm64] + exclude: + - goos: windows + goarch: arm + - goos: windows + goarch: arm64 + + steps: + - uses: actions/checkout@v3 + + - name: Set up Go + uses: actions/setup-go@v4 + with: + go-version: '1.24.0' + + - name: Build binary + run: | + mkdir -p build + GOOS=${{ matrix.goos }} GOARCH=${{ matrix.goarch }} go build -o build/tecamino-dbm-${{ matrix.goos }}-${{ matrix.goarch }} main.go + + - name: Upload artifacts + uses: actions/upload-artifact@v3 + with: + name: binaries + path: build/