Skip to content

Commit

Permalink
feat: add automatic publishing
Browse files Browse the repository at this point in the history
  • Loading branch information
Curve committed Jul 16, 2024
1 parent 8c451ec commit 7c7d36b
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 3 deletions.
29 changes: 28 additions & 1 deletion .github/workflows/python.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,16 @@
name: 🐍 Bindings

on:
release:
types:
- published
push:
pull_request:
workflow_dispatch:
inputs:
publish:
type: boolean
description: Publish on PyPi

jobs:
test-bindings:
Expand Down Expand Up @@ -119,5 +126,25 @@ jobs:
- name: 📦 Upload Artifact
uses: actions/upload-artifact@v4
with:
name: Wheels (${{ matrix.os }})
name: wheels-${{ matrix.os }}
path: ./wheelhouse/*.whl

deploy:
if: ${{ github.event_name == 'release' }} || ${{ github.event.inputs.publish == 'true' }}
needs: [package]

runs-on: ubuntu-latest
name: "🐍 Publish Bindings"

steps:
- name: 📦 Download Wheels
uses: actions/download-artifact@v4
with:
pattern: wheels-*
path: wheels
merge-multiple: true

- name: 🚀 Publish Wheels
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: https://test.pypi.org/legacy/
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,10 @@ build-backend = "scikit_build_core.build"

[project]
version = "4.0.0"
name = "ViennaLS_Python"
name = "ViennaLS"
readme = "README.md"
license = {file = "LICENSE"}
description = "A high performance sparse level set library"
# dependencies = ['vtk >= 9.0.0, < 10']

[project.urls]
Homepage = "https://viennatools.github.io/ViennaLS/"
Expand Down

0 comments on commit 7c7d36b

Please sign in to comment.