--- /dev/null
+name: Go
+
+on:
+ release:
+ types: [released,prereleased]
+ branches:
+ - master
+
+jobs:
+
+ build:
+ name: Build
+ runs-on: ubuntu-latest
+ steps:
+
+ - name: Set up Go 1.x
+ uses: actions/setup-go@v2
+ with:
+ go-version: ^1.15.2
+ id: go
+
+ - name: Check out code into the Go module directory
+ uses: actions/checkout@v2
+
+ - name: Get dependencies
+ run: |
+ go get -v -t -d ./...
+ if [ -f Gopkg.toml ]; then
+ curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh
+ dep ensure
+ fi
+
+ - name: Build
+ run: go build -v .
+
+ - name: Upload a Build Artifact
+ uses: actions/upload-artifact@v2.2.0
+ with:
+ # Artifact name
+ # A file, directory or wildcard pattern that describes what to upload
+ path: ./
+ # The desired behavior if no files are found using the provided path.