-
Notifications
You must be signed in to change notification settings - Fork 3
54 lines (46 loc) · 1.2 KB
/
ci.yml
File metadata and controls
54 lines (46 loc) · 1.2 KB
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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
name: CI
on:
push:
branches: [master]
jobs:
ci:
name: ci
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-go@v2
with:
go-version: 1.14
- name: Set SSH/Git config
env:
PRIVATE_KEY: ${{secrets.SSH_PRIVATE_KEY}}
run: |
mkdir -p ~/.ssh
echo "${PRIVATE_KEY}" > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
wc ~/.ssh/id_rsa
ssh-keyscan -H github.com > ~/.ssh/known_hosts
git config --global user.email "bot@github.com"
git config --global user.name "GitHub Actions"
- name: Dependency
run: make install
- name: golangci-lint
uses: golangci/golangci-lint-action@v2
with:
version: latest
- name: Build
run: make build
# - name: Test
# run: make test
# env:
# GITLAB_TOKEN: gitlab token
# GITLAB_BASE_URL: gitlab.com
# - name: Coverage
# uses: codecov/codecov-action@v1.0.0
# with:
# token: ${{secrets.CODECOV_TOKEN}}
# file: .coverage
- name: Release
uses: goreleaser/goreleaser-action@master
with:
args: release --snapshot --skip-publish --rm-dist