diff options
author | Roger Gonzalez <roger@rogs.me> | 2024-03-02 10:13:58 -0300 |
---|---|---|
committer | Roger Gonzalez <roger@rogs.me> | 2024-03-02 10:13:58 -0300 |
commit | f76daf6ddfac3cda577b16e3739b4460938d8288 (patch) | |
tree | 8575671971d6f1d1d545f68a05fa9a71e5728c2d | |
parent | f3245a6826f70572fa976fbae2bf7af06391a14f (diff) |
Using poetry and ruff on gitlab-ci
-rw-r--r-- | .gitlab-ci.yml | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 697c87d..350b74e 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -3,18 +3,18 @@ image: python:latest lint: stage: test before_script: - - pip install black flake8 isort flake8-bugbear flake8-builtins flake8-comprehensions flake8-tidy-imports flake8-eradicate flake8-print flake8-return flake8-use-fstring git+https://github.com/derrix060/flake8-expression-complexity.git + - pip install poetry + - poetry install --no-root script: - - black --check src/ - - flake8 src/ - - isort -c src/ + - poetry run ruff check ./src + - poetry run ruff format --check ./src deploy_to_pypi: stage: deploy only: - master before_script: - - pip install build twine + - pip install poetry + - poetry install --no-root script: - - python -m build - - TWINE_PASSWORD=$PYPI_PASSWORD TWINE_USERNAME=$PYPI_USERNAME python3 -m twine upload dist/* + - POETRY_PYPI_TOKEN_PYPI=$PYPI_PASSWORD poetry publish --build |