-
Notifications
You must be signed in to change notification settings - Fork 10
45 lines (38 loc) · 1.06 KB
/
poetry-pypi.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
name: Publish Python Package
on:
push:
tags:
- "v*.*.*"
jobs:
publish:
runs-on: ubuntu-latest
container:
image: ghcr.io/osgeo/gdal:ubuntu-full-3.7.2
env:
POETRY_NO_INTERACTION: 1
POETRY_VIRTUALENVS_IN_PROJECT: 1
POETRY_VIRTUALENVS_CREATE: 1
POETRY_CACHE_DIR: /tmp/poetry_cache
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Python
run: |
apt-get update
apt-get install -y python3-pip python3-dev
python -m pip install --upgrade pip
- name: Install Poetry
run: |
echo "Installing dependencies 🕵🏻♂️"
pip install poetry==1.6.1
- name: Configuring PyPI
run: |
echo "Configuring PyPI 🐍"
poetry config pypi-token.pypi ${{ secrets.PYPI_TOKEN }}
ldconfig
- name: Building and Publishing to PyPI
run: |
echo "Building the package 📦"
poetry build
echo "Publishing to PyPI 🔥"
poetry publish