|
12 | 12 | PYTHON_VERSION_DEFAULT: "3.10.8"
|
13 | 13 |
|
14 | 14 | jobs:
|
15 |
| - Test: |
16 |
| - runs-on: ubuntu-latest |
17 |
| - steps: |
18 |
| - - uses: actions/checkout@v4 |
19 |
| - with: |
20 |
| - fetch-depth: 1 |
21 |
| - - name: Set up Python |
22 |
| - uses: actions/setup-python@v5 |
23 |
| - with: |
24 |
| - python-version: ${{ env.PYTHON_VERSION_DEFAULT }} |
25 |
| - - name: Install and configure Poetry |
26 |
| - uses: snok/install-poetry@v1 |
27 |
| - with: |
28 |
| - virtualenvs-create: true |
29 |
| - virtualenvs-in-project: true |
30 |
| - installer-parallel: true |
31 |
| - - name: Load cached venv |
32 |
| - id: cached-poetry-dependencies |
33 |
| - uses: actions/cache@v3 |
34 |
| - with: |
35 |
| - path: .venv |
36 |
| - key: | |
37 |
| - venv-${{ runner.os }}-\ |
38 |
| - ${{ env.PYTHON_VERSION_DEFAULT }}-\ |
39 |
| - ${{ hashFiles('**/poetry.lock') }} |
40 |
| - - name: Validate project dependencies |
41 |
| - run: poetry check |
42 |
| - - name: Install dependencies |
43 |
| - if: steps.cached-poetry-dependencies.outputs.cache-hit != 'true' |
44 |
| - run: poetry install --no-interaction --no-root |
45 |
| - - name: Install library |
46 |
| - run: poetry install --no-interaction |
47 |
| - - name: Check dependencies |
48 |
| - run: poetry run deptry . |
49 |
| - - name: Run tests |
50 |
| - run: poetry run pytest |
51 |
| - |
52 | 15 | Release:
|
53 |
| - needs: Test |
54 | 16 | if: github.event_name == 'push' && !contains(github.event.head_commit.message, 'chore(release):')
|
55 | 17 | runs-on: ubuntu-latest
|
56 | 18 | permissions:
|
|
93 | 55 | run: poetry install --no-interaction --no-root
|
94 | 56 | - name: Python Semantic Release
|
95 | 57 | run: |
|
96 |
| - poetry run semantic-release --noop publish |
| 58 | + poetry run semantic-release publish |
97 | 59 | env:
|
98 | 60 | GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
99 | 61 | # PyPI_TOKEN: ${{secrets.PyPI_TOKEN}}
|
|
0 commit comments