poezio/.gitlab-ci.yml
Maxime “pep” Buquet 6378f6ee6b roezio: rework .gitlab-ci.yml
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
2022-08-21 17:19:58 +02:00

100 lines
2 KiB
YAML

stages:
- lint
- test
- build
build-doc:
stage: build
only:
- main@poezio/poezio
tags:
- www
image: python:3
script:
- ./update.sh
- . ./poezio-venv/bin/activate
- pip install sphinx --ignore-installed
- make doc
- rm -rf /www/latest
- mv doc/build/html/ /www/latest
build-ubuntu:
stage: build
image: python:3
script:
- python3 setup.py sdist
- python3 setup.py bdist
artifacts:
expire_in: 2 weeks
paths:
- dist/
only:
- main
security-check:
stage: lint
image: python:3
script:
- pip3 install safety
- safety check -r requirements.txt
.poezio-tests:
script:
- git clone https://lab.louiz.org/poezio/slixmpp.git
- pip3 install pytest pyasn1-modules cffi setuptools-rust --upgrade
- cd slixmpp
- python3 setup.py install
- cd ..
- python3 setup.py install
- py.test -v test/
- cargo test
pytest-3.7:
stage: test
image: docker.louiz.org/poezio/poezio:rust-python3.7
extends:
- .poezio-tests
pytest-3.8:
stage: test
image: docker.louiz.org/poezio/poezio:rust-python3.8
extends:
- .poezio-tests
pytest-3.9:
stage: test
image: docker.louiz.org/poezio/poezio:rust-python3.9
extends:
- .poezio-tests
pytest-3.10:
stage: test
image: docker.louiz.org/poezio/poezio:rust-python3.10
extends:
- .poezio-tests
pylint-plugins:
stage: lint
image: docker.louiz.org/poezio/poezio:rust-python3.10
allow_failure: true
script:
- pip3 install pylint pyasn1-modules cffi setuptools-rust --upgrade
- pip3 install -e git+https://lab.louiz.org/poezio/slixmpp.git#egg=slixmpp
- pip3 install -r requirements-plugins.txt
- python3 setup.py install
- pylint -E plugins
rust-lint:
stage: lint
image: docker.louiz.org/poezio/poezio:rust-python3.10
script:
- cargo fmt --check
- cargo clippy --no-deps
mypy:
stage: lint
image: python:3
script:
- pip3 install mypy types-setuptools
- mypy --ignore-missing-imports ./poezio
- mypy --ignore-missing-imports ./plugins