Files
natpass/.github/workflows/build.yml
T
2021-11-19 00:17:08 +08:00

50 lines
1.3 KiB
YAML

name: natpass
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os:
- ubuntu-18.04
- ubuntu-20.04
- windows-2016
- windows-2019
- windows-2022
- macos-10.15
- macos-11
go:
- '1.16'
- '1.17'
steps:
- uses: actions/checkout@v2
- name: Set up Go
uses: actions/setup-go@v2
with:
go-version: ${{ matrix.go }}
- name: Lint
run: |
go install golang.org/x/lint/golint@latest
golint -set_exit_status code/...
go install github.com/gordonklaus/ineffassign@latest
ineffassign ./...
- name: Build Server
run: go build -v code/server/main.go
- name: Build Client
run: |
go run contrib/bindata/main.go -pkg shell -o code/client/rule/shell/assets.go -prefix html/shell html/shell/...
go run contrib/bindata/main.go -pkg vnc -o code/client/rule/vnc/assets.go -prefix html/vnc html/vnc/...
go run contrib/bindata/main.go -pkg dashboard -o code/client/dashboard/assets.go -prefix html/dashboard html/dashboard/...
go build -v code/client/main.go