-
Notifications
You must be signed in to change notification settings - Fork 6
69 lines (60 loc) · 1.84 KB
/
ci_reuse_go_norebuild.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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
name: CI - golang
on:
workflow_call:
inputs:
ignore_copyright:
required: false
type: string
test_folder:
required: false
type: string
ignore_build:
required: false
type: string
secrets:
reporeading_token:
required: true
codecov_token:
required: true
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 'stable'
cache: false
- name: Checkout
uses: actions/checkout@v4
- name: Codecov
run: |
curl -Os https://uploader.codecov.io/latest/linux/codecov
chmod +x codecov
./codecov
- name: Check pull request file size
if: github.event_name == 'pull_request'
run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/checkPR.sh | bash
env:
token: ${{ secrets.reporeading_token }}
pr_number: ${{ github.event.number }}
- name: Cache Go - Modules
uses: actions/cache@v4
with:
path: ~/go/pkg/mod
key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }}
restore-keys: |
${{ runner.os }}-go-
- name: CI
uses: untillpro/ci-action@master
with:
ignore-build: ${{ inputs.ignore_build }}
ignore: ${{ inputs.ignsore_copyright }}
organization: 'untillpro,heeus'
token: ${{ secrets.reporeading_token }}
codecov-token: ${{ secrets.codecov_token }}
run-mod-tidy: false
- name: Check copyright
run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/check_copyright.sh | bash -s "$(go env GOPATH)"
- name: Linters
run: curl -s https://raw.githubusercontent.com/untillpro/ci-action/master/scripts/gbash.sh | bash -s "$(go env GOPATH)"