Skip to content
Snippets Groups Projects
Commit 8227eba6 authored by Sebastian Schubert's avatar Sebastian Schubert
Browse files

Added CI pipeline

parent 5b3f12c8
No related branches found
No related tags found
No related merge requests found
stages:
- linting
# Official language image. Look for the different tagged releases at:
# https://hub.docker.com/r/library/python/tags/
image: python:latest
# Change pip's cache directory to be inside the project directory since we can
# only cache local items.
variables:
PIP_CACHE_DIR: "$CI_PROJECT_DIR/.cache/pip"
VENV_DEV: ".venv"
# Pip's cache doesn't store the python packages
# https://pip.pypa.io/en/stable/topics/caching/
#
# If you want to also cache the installed packages, you have to install
# them in a virtualenv and cache it as well.
cache:
- key: pip_cache
paths:
- .cache/pip
when: always
- key: "$CI_PIPELINE_ID" # only used for one pipeline
paths:
- $VENV_DEV
when: always
before_script:
- python --version # For debugging
- |-
if [ ! -d $VENV_DEV ]; then
python3 -m venv $VENV_DEV
source $VENV_DEV/bin/activate
python3 -m pip install -r requirements-dev.txt
else
source $VENV_DEV/bin/activate
fi
isort:
stage: linting
dependencies: []
script:
- isort . --check-only
black:
stage: linting
dependencies: []
script:
- black --check .
[tool.isort]
profile = "black"
-r requirements.txt
black==23.1.0
isort==5.10.1
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment