-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfig.yml
51 lines (47 loc) · 1.19 KB
/
config.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
version: 2.1
orbs:
python: circleci/[email protected]
jobs:
test:
docker:
- image: "cimg/python:<<parameters.tag>>"
parameters:
tag:
default: "3.8"
type: string
steps:
- checkout # checkout source code to working directory
- run: python --version
- run:
command: python -m pip install --upgrade pip
name: upgrade pip
- python/install-packages:
pkg-manager: poetry
- run: poetry run pytest --cov --cov-report xml:reports/coverage.xml --junitxml=reports/test-results.xml
deploy:
docker:
- image: "cimg/python:3.8"
steps:
- checkout
- run: python patch_version.py $CIRCLE_TAG
- run: poetry build
- run: poetry publish -u __token__ -p $PYPI_TOKEN
workflows:
main:
jobs:
- test:
matrix:
parameters:
tag: [ "3.8", "3.9", "3.10", "3.11" ]
filters:
tags:
only: /.*/
- deploy:
context: pypi
requires:
- test
filters:
tags:
only: /[0-9]+(\.[0-9]+)*/
branches:
ignore: /.*/ # For testing only! /ci\/.*/