This repository was archived by the owner on Sep 1, 2025. It is now read-only.
File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1414 - git diff
1515 - test -z "$(git diff 2> /dev/null)" || exit 'Files are not generated or formatted with gofumpt, issue `make generate` and commit the result'
1616 - test -z "$(git ls-files --others --exclude-standard 2> /dev/null)" || exit 'Generation created untracked files, cannot proceed'
17- only :
18- - merge_requests
19- - branches
17+ rules :
18+ - if : $CI_PIPELINE_SOURCE == 'merge_request_event'
19+ - if : $CI_PIPELINE_SOURCE == 'push'
2020golangci_lint :
2121 stage : lint
2222 image :
@@ -26,9 +26,9 @@ golangci_lint:
2626 - go
2727 script :
2828 - golangci-lint run --enable-all
29- only :
30- - merge_requests
31- - branches
29+ rules :
30+ - if : $CI_PIPELINE_SOURCE == 'merge_request_event'
31+ - if : $CI_PIPELINE_SOURCE == 'push'
3232lint-commit-msg :
3333 stage : lint
3434 image :
@@ -38,8 +38,8 @@ lint-commit-msg:
3838 - go
3939 script :
4040 - /check
41- only :
42- - merge_requests
41+ rules :
42+ - if : $CI_PIPELINE_SOURCE == 'merge_request_event'
4343tidy :
4444 stage : lint
4545 image :
5050 script :
5151 - go mod tidy
5252 - test -z "$(git diff 2> /dev/null)" || exit 'Go modules not tidied, issue \`go mod tidy\` and commit the result'
53- only :
54- - merge_requests
55- - branches
53+ rules :
54+ - if : $CI_PIPELINE_SOURCE == 'merge_request_event'
55+ - if : $CI_PIPELINE_SOURCE == 'push'
5656test :
5757 stage : test
5858 image :
6363 script :
6464 - go build -v .
6565 - make test
66- only :
67- - merge_requests
68- - branches
66+ rules :
67+ - if : $CI_PIPELINE_SOURCE == 'merge_request_event'
68+ - if : $CI_PIPELINE_SOURCE == 'push'
You can’t perform that action at this time.
0 commit comments