Skip to content
Snippets Groups Projects
Commit fdb90f33 authored by GANGLOFF Hugo's avatar GANGLOFF Hugo 🤠
Browse files

add build and publish in CI

parent b8e055ad
No related branches found
No related tags found
No related merge requests found
Pipeline #91747 passed with stages
in 55 seconds
......@@ -2,6 +2,8 @@ image: "python:3.8"
stages:
- linting
- build
- publish
black:
stage: linting
......@@ -10,3 +12,30 @@ black:
- black --check --verbose -- .
tags:
- docker
build_package:
stage: build
before_script:
- pip install build
script:
- rm -rf dist/
- python -m build
artifacts:
untracked: true
expire_in: 1 week
tags:
- docker
publish_package:
stage: publish
before_script:
- pip install twine
script:
- TWINE_PASSWORD=${CI_JOB_TOKEN}
TWINE_USERNAME=gitlab-ci-token
python -m twine upload
--repository-url ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/pypi dist/*
tags:
- docker
only:
- tags
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