-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (34 loc) · 1002 Bytes
/
release.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
name: Upload CCL to PyPi
on:
release:
types: [published]
permissions:
contents: read
jobs:
deploy:
environment: release
runs-on: ubuntu-latest
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Load cached Poetry installation
uses: actions/cache@v3
with:
path: ~/.local
key: poetry-0 # To reset cache, increment
- name: Install Poetry
if: steps.cached-poetry.outputs.cache-hit != 'true'
uses: snok/install-poetry@v1
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
cache: "poetry"
- name: Install dependencies
run: poetry install -n
- name: Build package
run: poetry build -n
- name: Publish to PyPi
run: |
poetry config pypi-token.pypi "${{ secrets.PYPI_API_TOKEN }}"
poetry publish -n