From d500c5ce6ecf27014a635784b6fd627ce5128a39 Mon Sep 17 00:00:00 2001 From: Florent Fourcot Date: Wed, 30 Aug 2017 11:22:06 +0200 Subject: [PATCH] fix gitlab ci configuration for both python versions --- .gitlab-ci.yml | 111 ++++++++++++++++++++++++++----------------------- 1 file changed, 58 insertions(+), 53 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index c084671a2e..9e828fd150 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,57 +1,62 @@ -test:2.7: +before_script: + - "pip install -r .ci/requirements.txt" + - "REQUIREMENTS=$(mktemp) && python setup.py requirements > ${REQUIREMENTS} && pip install -r ${REQUIREMENTS} && rm ${REQUIREMENTS}" + - "pip install -r .ci/requirements_modules.txt" + +stages: + - "build27" + - "test27" + - "deploy27" + - "build3" + - "test3" + - "deploy3" + +build:2.7: image: "python:2.7" + stage: "build27" + script: + - "./tools/local_install.sh ~/bin" - before_script: - - "pip install -r .ci/requirements.txt" - - "REQUIREMENTS=$(mktemp) && python setup.py requirements > ${REQUIREMENTS} && pip install -r ${REQUIREMENTS} && rm ${REQUIREMENTS}" - - "pip install -r .ci/requirements_modules.txt" - - build: - stage: "build" - script: - - "./tools/local_install.sh ~/bin" - - lint: - stage: "test" - script: - - "./tools/pyflakes.sh" - - "./tools/weboob_lint.sh" - - unittests: - stage: "test" - script: - - "./tools/run_tests.sh" - - doc: - stage: "deploy" - script: - - "cd ./docs && make html" - -test:3: +lint:2.7: + image: "python:2.7" + stage: "test27" + script: + - "./tools/pyflakes.sh" + - "./tools/weboob_lint.sh" + +unittests:2.7: + image: "python:2.7" + stage: "test27" + script: + - "./tools/run_tests.sh" + +doc:2.7: + image: "python:2.7" + stage: "deploy27" + script: + - "cd ./docs && make html" + +build:3: image: "python:3" + stage: "build3" + script: + - "./tools/local_install.sh ~/bin" - before_script: - - "pip install -r .ci/requirements.txt" - - "REQUIREMENTS=$(mktemp) && python setup.py requirements > ${REQUIREMENTS} && pip install -r ${REQUIREMENTS} && rm ${REQUIREMENTS}" - - "pip install -r .ci/requirements_modules.txt" - - build: - stage: "build" - script: - - "./tools/local_install.sh ~/bin" - - lint: - stage: "test" - script: - - "./tools/pyflakes.sh" - - "./tools/weboob_lint.sh" - - unittests: - stage: "test" - script: - - "./tools/run_tests.sh -3" - - doc: - stage: "deploy" - script: - - "cd ./docs && make html" +lint:3: + image: "python:3" + stage: "test3" + script: + - "./tools/pyflakes.sh" + - "./tools/weboob_lint.sh" + +unittests:3: + image: "python:3" + stage: "test3" + script: + - "./tools/run_tests.sh -3" + +doc:3: + image: "python:3" + stage: "deploy3" + script: + - "cd ./docs && make html" -- GitLab