Bumps [actions/setup-go](https://github.com/actions/setup-go) from 2 to 3. - [Release notes](https://github.com/actions/setup-go/releases) - [Commits](https://github.com/actions/setup-go/compare/v2...v3) --- updated-dependencies: - dependency-name: actions/setup-go dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
56 lines
1.1 KiB
YAML
56 lines
1.1 KiB
YAML
name: Go
|
|
|
|
on:
|
|
push:
|
|
branches: [ master ]
|
|
pull_request:
|
|
types: [assigned, opened, synchronize, reopened]
|
|
release:
|
|
types: [ released ]
|
|
|
|
jobs:
|
|
|
|
build:
|
|
name: Build
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
|
|
- name: Set up Go 1.x
|
|
uses: actions/setup-go@v3
|
|
with:
|
|
go-version: ^1.18
|
|
id: go
|
|
|
|
- name: Check out code into the Go module directory
|
|
uses: actions/checkout@v3
|
|
with:
|
|
fetch-depth: 0
|
|
submodules: 'recursive'
|
|
|
|
|
|
- uses: dotnet/nbgv@master
|
|
with:
|
|
setAllVars: true
|
|
|
|
# - name: golangci-lint
|
|
# uses: golangci/golangci-lint-action@v3
|
|
# with:
|
|
# args: --timeout=10m -E gofmt
|
|
|
|
- name: Build
|
|
run: |
|
|
set -e
|
|
|
|
go build -o sshpiperd
|
|
./sshpiperd version
|
|
working-directory: sshpiperd
|
|
|
|
- name: Test
|
|
run: go test -v -race -cover ./...
|
|
working-directory: sshpiperd
|
|
|
|
- name: create release
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
run: |
|
|
gh release create -d --generate-notes v$NBGV_SimpleVersion
|