Skip to content

Commit

Permalink
Set up continuous deployment for PyPI releases (#2342)
Browse files Browse the repository at this point in the history
  • Loading branch information
adamjstewart committed Oct 10, 2024
1 parent 34c588b commit 53a1e9b
Showing 1 changed file with 45 additions and 0 deletions.
45 changes: 45 additions & 0 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
name: deploy
on:
release:
types:
- published
jobs:
build:
name: build
runs-on: ubuntu-latest
steps:
- name: Clone repo
uses: actions/[email protected]
- name: Set up python
uses: actions/[email protected]
with:
python-version: '3.12'
- name: Install pip dependencies
run: pip install build
- name: List pip dependencies
run: pip list
- name: Build project
run: python3 -m build
- name: Upload artifacts
uses: actions/[email protected]
with:
name: pypi-dist
path: dist/
pypi:
name: pypi
needs:
- build
environment:
name: pypi
url: https://pypi.org/p/torchgeo
permissions:
id-token: write
runs-on: ubuntu-latest
steps:
- name: Download artifacts
uses: actions/[email protected]
with:
name: pypi-dist
path: dist/
- name: Publish to PyPI
uses: pypa/[email protected]

0 comments on commit 53a1e9b

Please sign in to comment.