-
-
Notifications
You must be signed in to change notification settings - Fork 271
33 lines (31 loc) · 1.16 KB
/
go-ci-check.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
name: golangci-lint
on: [push, pull_request]
jobs:
golangci:
name: golang-lint
runs-on: ubuntu-latest
steps:
- uses: actions/setup-go@v3
with:
go-version: 1.18
- uses: actions/checkout@v3
- run: |
release_url=$(curl -s https://api.github.com/repos/eryajf/go-ldap-admin-ui/releases/latest | grep "browser_download_url" | grep -v 'dist.zip.md5' | cut -d '"' -f 4); wget $release_url && unzip dist.zip && rm dist.zip && mv dist public/static
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.57.2
args: --timeout=5m --skip-files="public/client/feishu/feishu.go"
build:
name: go-build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: |
release_url=$(curl -s https://api.github.com/repos/eryajf/go-ldap-admin-ui/releases/latest | grep "browser_download_url" | grep -v 'dist.zip.md5' | cut -d '"' -f 4); wget $release_url && unzip dist.zip && rm dist.zip && mv dist public/static
- name: Set up Go
uses: actions/setup-go@v3
with:
go-version: 1.18
- name: Build
run: go build -v ./...