Merge pull request #105 from cuishuang/main #122
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: Go Check | |
on: [push, pull_request] | |
jobs: | |
buildable: | |
name: Buildable and Runable | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- name: build | |
uses: actions/setup-go@v2 | |
with: | |
go-version: '1.17' | |
- run: | | |
export CGO_ENABLED=0 | |
GOOS=darwin GOARCH=amd64 go build -ldflags="-s -w " ./cmd/cdk/cdk.go | |
GOOS=linux GOARCH=386 go build -ldflags="-s -w " ./cmd/cdk/cdk.go | |
GOOS=linux GOARCH=arm go build -ldflags="-s -w " ./cmd/cdk/cdk.go | |
GOOS=linux GOARCH=arm64 go build -ldflags="-s -w " ./cmd/cdk/cdk.go | |
GOOS=linux GOARCH=amd64 go build -ldflags="-s -w " ./cmd/cdk/cdk.go | |
# test main function with Evaluate, Exploit and Tool | |
go test -v -timeout 30s -run ^TestParseCDKMain$ pkg/cli/*.go | |