diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml deleted file mode 100644 index 4dd71af92..000000000 --- a/.gitlab-ci.yml +++ /dev/null @@ -1,98 +0,0 @@ -image: condaforge/mambaforge - -stages: - - static code analysis - - tests - - build - - publish - -lint: - stage: static code analysis - script: - - mamba create -n lint-env black flake8 isort - - source activate lint-env - - isort --check . - - black --check . - - flake8 . - rules: - - when: always - -mypy: - stage: static code analysis - variables: - PYTHONHASHSEED: "0" - script: - - mamba env create -f imod-environment.yml - - source activate imod - - mamba install -y mypy mypy-gitlab-code-quality - - mypy --no-error-summary | mypy-gitlab-code-quality > codequality.json - artifacts: - when: always - reports: - codequality: codequality.json - allow_failure: true - rules: - - when: always - -unit tests and coverage: - stage: tests - variables: - NUMBA_DISABLE_JIT: "1" - script: - - apt-get update -q -y - - apt-get install -y build-essential curl - - apt-get install libgl1-mesa-glx -y - - mamba env create -f imod-environment.yml - - mamba env update -f imod-environment-dev.yml --prefix /opt/conda/envs/imod - - source activate imod - # Do editable install as pytest expects that - # https://github.com/scikit-hep/pyhf/issues/1456 - - pip install -e . - # Run tests - - cd imod/tests - - python -m pytest --cache-clear --verbose --junitxml=report.xml --cov=imod --cov-report term --cov-report xml:coverage.xml --cov-config=.coveragerc - coverage: '/(?i)total.*? (100(?:\.0+)?\%|[1-9]?\d(?:\.\d+)?\%)$/' - artifacts: - when: always - paths: - - imod/tests/coverage.xml - expire_in: 1 week - reports: - coverage_report: - coverage_format: cobertura - path: imod/tests/coverage.xml - junit: imod/tests/report.xml - rules: - - when: always - -build documentation: - stage: build - script: - - apt-get update -q -y - - apt-get install -y build-essential curl - - apt-get install libgl1-mesa-glx -y - - mamba env create -f imod-environment.yml --name imod - - mamba env update -f imod-environment-dev.yml --name imod - - source activate imod - - pip install -e . - - cd docs - - make html - artifacts: - paths: - - docs/_build/html/ - expire_in: 1 week - rules: - - if: $CI_MERGE_REQUEST_TARGET_BRANCH_NAME == "master" - - if: $CI_COMMIT_BRANCH == "master" - -pages: - stage: publish - dependencies: - - build documentation - script: - - mv docs/_build/html/ public/ - artifacts: - paths: - - public - rules: - - if: $CI_COMMIT_BRANCH == "master"