-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (35 loc) · 1.24 KB
/
publish_tilebox_datasets.yml
File metadata and controls
37 lines (35 loc) · 1.24 KB
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: Publish Tilebox Datasets
on:
release:
types: [published]
jobs:
release:
name: Build and Publish Tilebox Datasets
runs-on: ubuntu-latest
permissions:
contents: read # required for checkout
id-token: write # required trusted publishing to pypi.org
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
lfs: true
- name: Set up uv
uses: astral-sh/setup-uv@v2
with:
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: "Set up Python"
uses: actions/setup-python@v5
with:
python-version-file: "pyproject.toml"
- name: Print version
run: git describe --tags
- name: Build
run: mkdir dist && uv run python -m build tilebox-datasets && mv tilebox-datasets/dist/* dist/
- name: Publish to PyPi.org
if: github.event_name == 'release'
# authorization is done via OIDC, so we don't need to specify a token
# Instead, we've set up a trusted publishing config on pypi.org, that maps to this repository and the
# publish_tilebox_datasets workflow and maps it to the tilebox-datasets package on pypi.org
uses: pypa/gh-action-pypi-publish@release/v1