Skip to content

Commit

Permalink
Merge branch 'master' into dependabot/cargo/resvg-0.42.0
Browse files Browse the repository at this point in the history
  • Loading branch information
baseplate-admin committed Dec 12, 2024
2 parents 1941814 + 0a88b33 commit 131a25a
Show file tree
Hide file tree
Showing 3 changed files with 89 additions and 39 deletions.
74 changes: 62 additions & 12 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
@@ -1,14 +1,15 @@
# This file is autogenerated by maturin v1.5.1
# This file is autogenerated by maturin v1.7.4
# To update, run
#
# maturin generate-ci github
# maturin generate-ci github
#
name: CI

on:
push:
branches:
- '*'
- main
- master
tags:
- '*'
pull_request:
Expand All @@ -17,6 +18,12 @@ on:
permissions:
contents: read

env:
RUST_TOOLCHAIN: 'nightly'
CARGO_UNSTABLE_SPARSE_REGISTRY: 'true'
UNSAFE_PYO3_BUILD_FREE_THREADED: '1'
UNSAFE_PYO3_SKIP_VERSION_CHECK: '1'

jobs:
linux:
runs-on: ${{ matrix.platform.runner }}
Expand All @@ -39,12 +46,12 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: 3.13
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist --find-interpreter
args: --release --out dist -i 3.8 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10
sccache: 'true'
manylinux: auto
- name: Upload wheels
Expand All @@ -53,6 +60,37 @@ jobs:
name: wheels-linux-${{ matrix.platform.target }}
path: dist

musllinux:
runs-on: ${{ matrix.platform.runner }}
strategy:
matrix:
platform:
- runner: ubuntu-latest
target: x86_64
- runner: ubuntu-latest
target: x86
- runner: ubuntu-latest
target: aarch64
- runner: ubuntu-latest
target: armv7
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.13
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist -i 3.8 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10
sccache: 'true'
manylinux: musllinux_1_2
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-musllinux-${{ matrix.platform.target }}
path: dist

windows:
runs-on: ${{ matrix.platform.runner }}
strategy:
Expand All @@ -66,13 +104,13 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: 3.13
architecture: ${{ matrix.platform.target }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist --find-interpreter
args: --release --out dist -i 3.8 3.9 3.10 3.11 3.12 3.13
sccache: 'true'
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand All @@ -85,20 +123,20 @@ jobs:
strategy:
matrix:
platform:
- runner: macos-latest
- runner: macos-12
target: x86_64
- runner: macos-14
target: aarch64
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: 3.13
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist --find-interpreter
args: --release --out dist -i 3.8 3.9 3.10 3.11 3.12 3.13 pypy3.9 pypy3.10
sccache: 'true'
- name: Upload wheels
uses: actions/upload-artifact@v4
Expand All @@ -124,11 +162,23 @@ jobs:
release:
name: Release
runs-on: ubuntu-latest
if: "startsWith(github.ref, 'refs/tags/')"
needs: [linux, windows, macos, sdist]
if: ${{ startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch' }}
needs: [linux, musllinux, windows, macos, sdist]
permissions:
# Use to sign the release artifacts
id-token: write
# Used to upload release artifacts
contents: write
# Used to generate artifact attestation
attestations: write
steps:
- uses: actions/download-artifact@v4
- name: Generate artifact attestation
uses: actions/attest-build-provenance@v1
with:
subject-path: 'wheels-*/*'
- name: Publish to PyPI
if: "startsWith(github.ref, 'refs/tags/')"
uses: PyO3/maturin-action@v1
env:
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
Expand Down
44 changes: 22 additions & 22 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions src/rust/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -345,11 +345,11 @@ fn svg_to_bytes(
background: _background,
skip_system_fonts: skip_system_fonts.unwrap_or(false),
fit_to,
serif_family:serif_family,
sans_serif_family:sans_serif_family,
cursive_family:cursive_family,
fantasy_family:fantasy_family,
monospace_family:monospace_family,
serif_family,
sans_serif_family,
cursive_family,
fantasy_family,
monospace_family,
font_files,
font_dirs,
};
Expand Down

0 comments on commit 131a25a

Please sign in to comment.