1
0
Fork 0
telegram/.gitlab-ci.yml

40 lines
625 B
YAML
Raw Normal View History

2018-07-29 15:41:59 +00:00
image: golang:alpine
variables:
GO111MOD: "on"
CGO_ENABLED: "0"
GOOS: "linux"
cache:
key: ${CI_COMMIT_REF_SLUG}
paths:
- /var/cache/apk
- /go/pkg/mod
2018-07-29 15:41:59 +00:00
stages:
- test
- review
2018-07-29 15:41:59 +00:00
before_script:
- apk add --no-cache git make
- go get github.com/golangci/golangci-lint/cmd/golangci-lint
- go install github.com/golangci/golangci-lint/cmd/golangci-lint
- make tidy
2018-07-29 15:41:59 +00:00
unit_tests:
stage: test
script:
- make test
code_coverage:
stage: test
script:
- make coverage
coverage: '/^coverage:\s(\d+(?:\.\d+)?%)/'
2018-07-29 15:41:59 +00:00
lint_code:
stage: review
2018-07-29 15:41:59 +00:00
script:
- make lint
allow_failure: true