Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Create a release from tag

permissions: {}

on:
push:
tags:
- '*'

jobs:
build:
name: Build and store python artifacts
runs-on: ubuntu-latest
permissions:
contents: read

steps:
- uses: actions/checkout@v4
with:
persist-credentials: false

- uses: ./.github/actions/uv-setup/

- name: Build
run: uv build

- name: Store python distribution artifacts
uses: actions/upload-artifact@v4
with:
name: artifacts
path: dist/

release:
permissions:
contents: write # allow creating a release

name: "Create and package a release"
runs-on: ubuntu-latest
needs: [build]
steps:
- name: Retrieve distribution artifacts
uses: actions/download-artifact@v4
with:
name: artifacts
path: dist/

- name: Create release ${{ github.ref_name }}
shell: bash
run: |
gh release create ${GITHUB_REF_NAME} --repo ${{ github.repository }} --generate-notes dist/*
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
__pycache__

# Distribution / packaging
dist/
*.egg-info/
Loading