File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches : [ main, feature/* ]
6+ tags :
7+ - ' v*'
8+ pull_request :
9+ branches : [ main ]
10+
11+ jobs :
12+ test :
13+ runs-on : ubuntu-latest
14+ strategy :
15+ matrix :
16+ python-version : ["3.9", "3.10", "3.11"]
17+
18+ steps :
19+ - uses : actions/checkout@v4
20+
21+ - name : Set up Python ${{ matrix.python-version }}
22+ uses : actions/setup-python@v5
23+ with :
24+ python-version : ${{ matrix.python-version }}
25+
26+ - name : Install dependencies
27+ run : |
28+ python -m pip install --upgrade pip
29+ pip install -e .
30+
31+ - name : Run tests
32+ run : python tests/runner.py
33+
34+ publish :
35+ if : startsWith(github.ref, 'refs/tags/v')
36+ needs : test
37+ runs-on : ubuntu-latest
38+ permissions :
39+ id-token : write
40+ contents : read
41+
42+ steps :
43+ - uses : actions/checkout@v4
44+
45+ - name : Set up Python
46+ uses : actions/setup-python@v5
47+ with :
48+ python-version : " 3.11"
49+
50+ - name : Install build tools
51+ run : |
52+ python -m pip install --upgrade pip
53+ pip install build
54+
55+ - name : Build package
56+ run : python -m build
57+
58+ - name : Publish to PyPI
59+ uses : pypa/gh-action-pypi-publish@release/v1
You can’t perform that action at this time.
0 commit comments