diff --git a/{{cookiecutter.repo_name}}/.gitlab-ci.yml b/{{cookiecutter.repo_name}}/.gitlab-ci.yml index c6fd435..a953868 100644 --- a/{{cookiecutter.repo_name}}/.gitlab-ci.yml +++ b/{{cookiecutter.repo_name}}/.gitlab-ci.yml @@ -1,42 +1,40 @@ test: + image: + name: pretix/ci-image + before_script: + - pip install -U pip uv + - uv pip install --system -U wheel setuptools pytest pytest-django coverage + - uv pip install --system -U git+https://github.com/pretix/pretix.git@master#egg=pretix script: - - cp /keys/.pypirc ~/.pypirc - - virtualenv /tmp/env - - source /tmp/env/bin/activate - - XDG_CACHE_HOME=/cache pip3 install -U pip wheel setuptools pytest pytest-django coverage - - XDG_CACHE_HOME=/cache pip3 install -U "git+https://github.com/pretix/pretix.git@master#egg=pretix" - - python setup.py develop + - uv pip install --system -e . - make - coverage run -m pytest tests - coverage report - tags: - - python3 style: + image: + name: pretix/ci-image + before_script: + - pip install -U pip uv + - uv pip install --system -U wheel setuptools isort black flake8 check-manifest + - uv pip install --system -U git+https://github.com/pretix/pretix.git@master#egg=pretix script: - - cp /keys/.pypirc ~/.pypirc - - virtualenv /tmp/env - - source /tmp/env/bin/activate - - XDG_CACHE_HOME=/cache pip3 install -U pip wheel setuptools isort black flake8 check-manifest - - XDG_CACHE_HOME=/cache pip3 install -U "git+https://github.com/pretix/pretix.git@master#egg=pretix" - - python setup.py develop + - uv pip install --system -e . - black --check . - - isort -c . - - flake8 . - - check-manifest . - tags: - - python3 + - isort -c --gitignore . + - flake8 --extend-exclude .cache . + - check-manifest --ignore .cache . pypi: + image: + name: pretix/ci-image + before_script: + - cat $PYPIRC > ~/.pypirc + - pip install -U pip uv + - uv pip install --system -U wheel setuptools twine build pretix-plugin-build check-manifest script: - - cp /keys/.pypirc ~/.pypirc - - virtualenv /tmp/env - - source /tmp/env/bin/activate - - XDG_CACHE_HOME=/cache pip3 install -U pip wheel setuptools twine build pretix-plugin-build check-manifest - python -m build - check-manifest . - twine check dist/* - twine upload dist/* - tags: - - python3 only: - pypi artifacts: