mirror of
https://gitlab2.federez.net/re2o/re2o
synced 2024-11-24 12:23:11 +00:00
Switch to GitLab codeclimate CI
This commit is contained in:
parent
ca1005d58c
commit
1900449c7a
2 changed files with 24 additions and 15 deletions
7
.codeclimate.yml
Normal file
7
.codeclimate.yml
Normal file
|
@ -0,0 +1,7 @@
|
|||
engines:
|
||||
pylint:
|
||||
enabled: true
|
||||
channel: "beta"
|
||||
plugins:
|
||||
- django
|
||||
|
|
@ -1,20 +1,22 @@
|
|||
---
|
||||
image: debian:stretch
|
||||
stages:
|
||||
- lint
|
||||
- codequality
|
||||
|
||||
lint:
|
||||
stage: lint
|
||||
code_quality:
|
||||
stage: codequality
|
||||
image: docker:stable
|
||||
variables:
|
||||
LANG: 'en_US.UTF-8'
|
||||
LC_ALL: 'en_US.UTF-8'
|
||||
LANGUAGE: 'en_US.UTF-8'
|
||||
DOCKER_DRIVER: overlay2
|
||||
allow_failure: true
|
||||
services:
|
||||
- docker:stable-dind
|
||||
script:
|
||||
- apt-get -qq update
|
||||
- DEBIAN_FRONTEND=noninteractive apt-get -qq install -y locales python3-django python3-pylint-django
|
||||
- sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && dpkg-reconfigure --frontend=noninteractive locales && update-locale LANG=en_US.UTF-8
|
||||
- pylint3 --load-plugins pylint_django cotisations machines re2o logs topologie preferences search users || if [ $? -ne 1 ]; then exit 0; else exit 1; fi
|
||||
|
||||
|
||||
|
||||
|
||||
- export SP_VERSION=$(echo "$CI_SERVER_VERSION" | sed 's/^\([0-9]*\)\.\([0-9]*\).*/\1-\2-stable/')
|
||||
- docker run
|
||||
--env SOURCE_CODE="$PWD"
|
||||
--volume "$PWD":/code
|
||||
--volume /var/run/docker.sock:/var/run/docker.sock
|
||||
"registry.gitlab.com/gitlab-org/security-products/codequality:$SP_VERSION" /code
|
||||
artifacts:
|
||||
reports:
|
||||
codequality: gl-code-quality-report.json
|
||||
|
|
Loading…
Reference in a new issue