-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (30 loc) · 903 Bytes
/
ci.yaml
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
name: CI
on:
push:
branches:
- '**' # This will run the workflow on every push to any branch
jobs:
build_and_test:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Run tests
run: make test-ci
pypi-publish:
needs: build_and_test
if: github.ref == 'refs/heads/main'
name: upload release to PyPI
runs-on: ubuntu-latest
# Specifying a GitHub environment is optional, but strongly encouraged
environment: release
permissions:
# IMPORTANT: this permission is mandatory for trusted publishing
id-token: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install Poetry & Build
run: pip install poetry; poetry build
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1