Skip to content
Snippets Groups Projects
Commit d645607c authored by Pierre Smeyers's avatar Pierre Smeyers
Browse files

fix(ci-lint): golangci-lint V2 no longer support --out-format arg

parent 21e3659e
No related branches found
No related tags found
No related merge requests found
...@@ -719,7 +719,14 @@ go-ci-lint: ...@@ -719,7 +719,14 @@ go-ci-lint:
script: script:
- mkdir -p -m 777 reports - mkdir -p -m 777 reports
# produce all reports at once # produce all reports at once
- golangci-lint run --out-format "colored-line-number:stdout,code-climate:reports/go-ci-lint.codeclimate.json,checkstyle:reports/go-ci-lint.checkstyle.xml" $GO_CI_LINT_ARGS - |
glc_ver_major=$(golangci-lint version | cut -d' ' -f4 | cut -d'.' -f1)
if [[ "$glc_major_ver" == "1" ]]
then
golangci-lint run --out-format "colored-line-number:stdout,code-climate:reports/go-ci-lint.codeclimate.json,checkstyle:reports/go-ci-lint.checkstyle.xml" $GO_CI_LINT_ARGS
else
golangci-lint run --output.text.path stdout --output.code-climate.path reports/go-ci-lint.codeclimate.json --output.checkstyle.path reports/go-ci-lint.checkstyle.xml $GO_CI_LINT_ARGS
fi
artifacts: artifacts:
name: "$CI_JOB_NAME artifacts from $CI_PROJECT_NAME on $CI_COMMIT_REF_SLUG" name: "$CI_JOB_NAME artifacts from $CI_PROJECT_NAME on $CI_COMMIT_REF_SLUG"
expire_in: 1 day expire_in: 1 day
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment