From cc6ddff9bc7d7617d9be910939e858bcaa0c55e0 Mon Sep 17 00:00:00 2001 From: Raoul Snyman Date: Tue, 3 May 2022 13:54:31 -0700 Subject: [PATCH] Add config for Woodpecker CI --- .woodpecker.yml | 100 ++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 .woodpecker.yml diff --git a/.woodpecker.yml b/.woodpecker.yml new file mode 100644 index 000000000..332b0adc8 --- /dev/null +++ b/.woodpecker.yml @@ -0,0 +1,100 @@ +pipeline: + lint-python: + group: test + image: openlp/debian + commands: + - sh scripts/generate_resources.sh + - flake8 + + lint-javascript: + group: test + image: openlp/angular + commands: + - yarn install + - yarn lint + + test-debian: + group: test + image: openlp/debian + commands: + - sh scripts/generate_resources.sh + - xvfb-run -s '-screen 0 1024x768x24' pytest-3 --color=no --disable-warnings --cov openlp --cov-report term + - mv .coverage linux.coverage + # artifacts: + # paths: + # - linux.coverage + + test-ubuntu: + group: test + image: openlp/ubuntu + commands: + - sh scripts/generate_resources.sh + - xvfb-run -s '-screen 0 1024x768x24' pytest-3 --color=no --disable-warnings + + test-fedora: + group: test + image: openlp/fedora + commands: + - sh scripts/generate_resources.sh + - xvfb-run -s '-screen 0 1024x768x24' pytest-3 --color=no --disable-warnings + + test-arch: + group: test + image: openlp/arch + commands: + - sh scripts/generate_resources.sh + - xvfb-run -s '-screen 0 1024x768x24' pytest --color=no --disable-warnings + + test-macos: + group: test + tags: + - macos + commands: + - export PATH=/opt/local/bin:$PATH + - sh scripts/generate_resources.sh + - python3 -m pytest --color=no --disable-warnings --cov openlp + - mv .coverage macos.coverage + # artifacts: + # paths: + # - macos.coverage + when: + branch: master + repo: openlp/openlp + + test-display: + group: test + image: openlp/angular + commands: + - yarn install + - yarn test --browsers ChromiumHeadlessCI + + upload-pypi: + group: deploy + image: openlp/debian + commands: + - python3 setup.py sdist bdist_wheel + - twine upload dist/* + when: + repo: openlp/openlp + event: tag + branch: master + + # pages: + # group: deploy + # image: openlp/debian + # commands: + # - fixpaths linux.coverage + # - fixpaths macos.coverage + # - python3-coverage combine linux.coverage macos.coverage + # - python3-coverage html + # - mv htmlcov public + # - python3-coverage report + # artifacts: + # paths: + # - public + # expire_in: 30 days + # depends_on: + # - test-debian + # - test-macos + # only: + # - master@openlp/openlp