File tree 3 files changed +86
-42
lines changed
3 files changed +86
-42
lines changed Original file line number Diff line number Diff line change 7
7
pull_request :
8
8
9
9
jobs :
10
- build :
10
+ build_lint_test :
11
11
runs-on : ubuntu-latest
12
12
steps :
13
13
- name : Checkout
14
14
uses : actions/checkout@v4
15
+
15
16
- name : Setup go
16
17
uses : actions/setup-go@v5
17
18
with :
18
19
go-version-file : go.mod
20
+
19
21
- name : Setup Mage
20
22
uses : magefile/mage-action@v3
21
23
with :
22
24
install-only : true
23
25
26
+ - name : Install test dependencies
27
+ run : |
28
+ sudo apt update
29
+ sudo apt install -y gcc
30
+
31
+ - name : Setup CI Linter
32
+ run : curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.54.2
33
+
24
34
- name : Build
25
35
run : |
26
36
mage -v build
27
37
28
- test :
29
- runs-on : ubuntu-latest
30
- needs : build
31
- steps :
32
- - name : Checkout
33
- uses : actions/checkout@v4
34
- - name : Setup go
35
- uses : actions/setup-go@v5
36
- with :
37
- go-version-file : go.mod
38
- - name : Install dependencies
38
+ - name : Lint
39
39
run : |
40
- sudo apt update
41
- sudo apt install -y gcc
42
-
43
- - name : Setup Mage
44
- uses : magefile/mage-action@v3
45
- with :
46
- install-only : true
40
+ mage -v lint
47
41
48
42
- name : Test
49
43
run : |
Load Diff This file was deleted.
Original file line number Diff line number Diff line change
1
+ ---
2
+ # This file must be signed. You can do so with the `mage drone` command
3
+
4
+ kind : pipeline
5
+ type : docker
6
+ name : main
7
+
8
+ platform :
9
+ os : linux
10
+ arch : amd64
11
+
12
+ trigger :
13
+ branch : main
14
+ event :
15
+ - push
16
+
17
+ steps :
18
+ - name : build
19
+ image : grafana/grafana-plugin-ci:1.9.5
20
+ commands :
21
+ - mage -v build
22
+
23
+ - name : lint
24
+ image : grafana/grafana-plugin-ci:1.9.5
25
+ commands :
26
+ - mage -v lint
27
+
28
+ - name : test
29
+ image : grafana/grafana-plugin-ci:1.9.5
30
+ commands :
31
+ # -race requires cgo + a C compiler
32
+ - apt update
33
+ - apt install -y gcc
34
+ - mage -v testRace
35
+ environment :
36
+ CGO_ENABLED : " 1"
37
+ ---
38
+ kind : pipeline
39
+ type : docker
40
+ name : pr
41
+
42
+ platform :
43
+ os : linux
44
+ arch : amd64
45
+
46
+ trigger :
47
+ event :
48
+ # - pull_request
49
+
50
+ steps :
51
+ - name : build
52
+ image : grafana/grafana-plugin-ci:1.9.5
53
+ commands :
54
+ - mage -v build
55
+
56
+ - name : lint
57
+ image : grafana/grafana-plugin-ci:1.9.5
58
+ commands :
59
+ - mage -v lint
60
+
61
+ - name : test
62
+ image : grafana/grafana-plugin-ci:1.9.5
63
+ commands :
64
+ # -race requires cgo + a C compiler
65
+ - apt update
66
+ - apt install -y gcc
67
+ - mage -v testRace
68
+ environment :
69
+ CGO_ENABLED : " 1"
70
+
71
+ ---
72
+ kind : signature
73
+ hmac : cee688a6f8ed3ecb1ddd384e349a6556d28b23b298057d8fa02da37ab50b0ba7
You can’t perform that action at this time.
0 commit comments