Skip to content

Commit

Permalink
chore: update toml and publish.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
robertodr committed Jul 24, 2024
1 parent b9fa882 commit 22df743
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 19 deletions.
27 changes: 11 additions & 16 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ env:

jobs:
build_sdist:
name: Build SDist
name: Build source distribution
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -29,11 +29,9 @@ jobs:
- name: Build SDist
run: pipx run build --sdist

- name: Check metadata
run: pipx run twine check dist/*

- uses: actions/upload-artifact@v4
with:
name: cibw-sdist
path: dist/*.tar.gz

generate-wheels-matrix:
Expand Down Expand Up @@ -90,8 +88,6 @@ jobs:

- uses: pypa/[email protected]
env:
CIBW_MANYLINUX_X86_64_IMAGE: "manylinux_2_28"

# skip testing PyPy builds
CIBW_TEST_SKIP: "pp*"

Expand All @@ -110,28 +106,27 @@ jobs:
run: git diff --exit-code
shell: bash

- name: Upload wheels
uses: actions/upload-artifact@v4
- uses: actions/upload-artifact@v4
with:
path: wheelhouse/*.whl
name: cibw-wheels-${{ matrix.os }}-${{ strategy.job-index }}
path: ./wheelhouse/*.whl

upload_all:
name: Upload if release
needs:
- build_wheels
- build_sdist
- make_sdist
environment: pypi
permissions:
id-token: write
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'

steps:
- uses: actions/setup-python@v4

- uses: actions/download-artifact@v4
with:
name: artifact
pattern: cibw-*
path: dist
merge-multiple: true

- uses: pypa/gh-action-pypi-publish@v1
with:
user: __token__
password: ${{ secrets.pypi_password }}
8 changes: 5 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
[build-system]
requires = ["scikit-build-core >=0.4.3", "pybind11"]
requires = ["scikit-build-core >=0.8", "pybind11"]
build-backend = "scikit_build_core.build"

[project]
Expand Down Expand Up @@ -50,7 +50,7 @@ Changelog = "https://github.com/org/maxscheurer/releases"

[tool.scikit-build]
# Protect the configuration against future changes in scikit-build-core
minimum-version = "0.4"
minimum-version = "build-system.requires"

# Setuptools-style build caching in a local directory
build-dir = "build/{wheel_tag}"
Expand All @@ -59,6 +59,8 @@ build-dir = "build/{wheel_tag}"
wheel.py-api = "cp312"

cmake.verbose = true
cmake.version = ">=3.16"
ninja.make-fallback = false
logging.level = "INFO"
metadata.version.provider = "scikit_build_core.metadata.setuptools_scm"
sdist.cmake = true
Expand All @@ -70,7 +72,7 @@ sdist.include = [

[tool.setuptools_scm]
write_to = "src/cppe/_version.py"
fallback_version = "0.3.1"
fallback_version = "0.3.2"

[tool.pytest.ini_options]
minversion = "6.0"
Expand Down

0 comments on commit 22df743

Please sign in to comment.