Commit 5d37015 1 parent bc3cace commit 5d37015 Copy full SHA for 5d37015
File tree 3 files changed +39
-4
lines changed
3 files changed +39
-4
lines changed Original file line number Diff line number Diff line change 1
1
name : GitGuardian scan
2
2
3
- on : [push, pull_request]
3
+ on :
4
+ workflow_dispatch :
5
+ push :
4
6
5
7
jobs :
6
8
scanning :
16
18
env :
17
19
GITHUB_PUSH_BEFORE_SHA : ${{ github.event.before }}
18
20
GITHUB_PUSH_BASE_SHA : ${{ github.event.base }}
19
- GITHUB_PULL_BASE_SHA : ${{ github.event.pull_request.base.sha }}
21
+ GITHUB_PULL_BASE_SHA : ${{ github.event.pull_request.base.sha }}
20
22
GITHUB_DEFAULT_BRANCH : ${{ github.event.repository.default_branch }}
21
23
GITGUARDIAN_API_KEY : ${{ secrets.GITGUARDIAN_API_KEY }}
Original file line number Diff line number Diff line change
1
+ name : Linters, static checks and code coverage
2
+
3
+ on :
4
+ workflow_dispatch :
5
+ # push:
6
+ # branches: [main, dk-add-linters]
7
+ # paths-ignore:
8
+ # - "docs/**"
9
+ # - "**.md"
10
+ # pull_request:
11
+ # paths-ignore:
12
+ # - "docs/**"
13
+ # - "**.md"
14
+
15
+ jobs :
16
+ run-linters :
17
+ runs-on : ubuntu-latest
18
+ steps :
19
+ - uses : actions/checkout@v3
20
+ # - name: Run static check
21
+ # uses: dominikh/[email protected]
22
+ # - name: Run static check
23
+ # uses: reviewdog/action-staticcheck@v1
24
+ # with:
25
+ # # TODO: pick filter https://github.com/reviewdog/reviewdog#filter-mode
26
+ # filter_mode: nofilter
Original file line number Diff line number Diff line change @@ -62,12 +62,19 @@ jobs:
62
62
# Only run if the test failed on target version to avoid duplicated annotations on GitHub.
63
63
if : ${{ always() && env.TARGET_GOLANG_VERSION == matrix.go }}
64
64
uses : reviewdog/action-staticcheck@v1
65
+ with :
66
+ # TODO: pick filter https://github.com/reviewdog/reviewdog#filter-mode
67
+ filter_mode : nofilter
68
+ - name : Run golangci-lint
69
+ # Only run if the test failed on target version to avoid duplicated annotations on GitHub.
70
+ if : ${{ always() && env.TARGET_GOLANG_VERSION == matrix.go }}
71
+ uses : golangci/golangci-lint-action@v3
65
72
# TODO(@okdas): move coverage to a separate job
66
73
- name : create coverage report
67
- if : ${{ env.TARGET_GOLANG_VERSION == matrix.go }}
74
+ if : ${{ always() && env.TARGET_GOLANG_VERSION == matrix.go }}
68
75
run : make test_all_with_coverage
69
76
- name : Upload coverage to Codecov
70
- if : ${{ env.TARGET_GOLANG_VERSION == matrix.go }}
77
+ if : ${{ always() && env.TARGET_GOLANG_VERSION == matrix.go }}
71
78
uses : codecov/codecov-action@v3
72
79
73
80
# TODO(@okdas): reuse artifacts built by the previous job instead
You can’t perform that action at this time.
0 commit comments