Skip to content

Merge pull request #434 from mitre/clenk/update-go-deps #241

Merge pull request #434 from mitre/clenk/update-go-deps

Merge pull request #434 from mitre/clenk/update-go-deps #241

Workflow file for this run

name: Sandcat Basic
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 1
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: 1.19
- name: Mod tidy
run: |
cd gocat
go mod tidy
- name: Build Windows
run: |
cd gocat
go build -o sandcat.go-windows -ldflags="-s -w" sandcat.go
file sandcat.go-windows && ls -al sandcat.go-windows
env:
GOOS: windows
- name: Build Darwin amd64
run: |
cd gocat
go build -o sandcat.go-darwin-amd64 -ldflags="-s -w" sandcat.go
file sandcat.go-darwin-amd64 && ls -al sandcat.go-darwin-amd64
env:
GOOS: darwin
GOARCH: amd64
- name: Build Darwin arm64
run: |
cd gocat
go build -o sandcat.go-darwin-arm64 -ldflags="-s -w" sandcat.go
file sandcat.go-darwin-arm64 && ls -al sandcat.go-darwin-arm64
env:
GOOS: darwin
GOARCH: arm64
- name: Build Linux
run: |
cd gocat
go build -o sandcat.go-linux -ldflags="-s -w" sandcat.go
file sandcat.go-linux && ls -al sandcat.go-linux && ./sandcat.go-linux -help
env:
GOOS: linux
- name: Golang Unit Tests
run: |
cd gocat
go test -v ./...