This PR contains the following updates: | Package | Type | Update | Change | |---|---|---|---| | [actions/upload-artifact](https://redirect.github.com/actions/upload-artifact) | action | minor | `v4` -> `v4.6.2` | --- > [!WARNING] > Some dependencies could not be looked up. Check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>actions/upload-artifact (actions/upload-artifact)</summary> ### [`v4.6.2`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.6.2) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.6.1...v4.6.2) #### What's Changed - Update to use artifact 2.3.2 package & prepare for new upload-artifact release by [@​salmanmkc](https://redirect.github.com/salmanmkc) in [https://github.com/actions/upload-artifact/pull/685](https://redirect.github.com/actions/upload-artifact/pull/685) #### New Contributors - [@​salmanmkc](https://redirect.github.com/salmanmkc) made their first contribution in [https://github.com/actions/upload-artifact/pull/685](https://redirect.github.com/actions/upload-artifact/pull/685) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.6.2 ### [`v4.6.1`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.6.1) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.6.0...v4.6.1) #### What's Changed - Update to use artifact 2.2.2 package by [@​yacaovsnc](https://redirect.github.com/yacaovsnc) in [https://github.com/actions/upload-artifact/pull/673](https://redirect.github.com/actions/upload-artifact/pull/673) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.6.1 ### [`v4.6.0`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.6.0) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.5.0...v4.6.0) ##### What's Changed - Expose env vars to control concurrency and timeout by [@​yacaovsnc](https://redirect.github.com/yacaovsnc) in [https://github.com/actions/upload-artifact/pull/662](https://redirect.github.com/actions/upload-artifact/pull/662) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.6.0 ### [`v4.5.0`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.5.0) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.4.3...v4.5.0) ##### What's Changed - fix: deprecated `Node.js` version in action by [@​hamirmahal](https://redirect.github.com/hamirmahal) in [https://github.com/actions/upload-artifact/pull/578](https://redirect.github.com/actions/upload-artifact/pull/578) - Add new `artifact-digest` output by [@​bdehamer](https://redirect.github.com/bdehamer) in [https://github.com/actions/upload-artifact/pull/656](https://redirect.github.com/actions/upload-artifact/pull/656) ##### New Contributors - [@​hamirmahal](https://redirect.github.com/hamirmahal) made their first contribution in [https://github.com/actions/upload-artifact/pull/578](https://redirect.github.com/actions/upload-artifact/pull/578) - [@​bdehamer](https://redirect.github.com/bdehamer) made their first contribution in [https://github.com/actions/upload-artifact/pull/656](https://redirect.github.com/actions/upload-artifact/pull/656) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.4.3...v4.5.0 ### [`v4.4.3`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.4.3) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.4.2...v4.4.3) #### What's Changed - Undo indirect dependency updates from [#​627](https://redirect.github.com/actions/upload-artifact/issues/627) by [@​joshmgross](https://redirect.github.com/joshmgross) in [https://github.com/actions/upload-artifact/pull/632](https://redirect.github.com/actions/upload-artifact/pull/632) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.4.2...v4.4.3 ### [`v4.4.2`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.4.2) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.4.1...v4.4.2) #### What's Changed - Bump `@actions/artifact` to 2.1.11 by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/627](https://redirect.github.com/actions/upload-artifact/pull/627) - Includes fix for relative symlinks not resolving properly **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.4.1...v4.4.2 ### [`v4.4.1`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.4.1) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.4.0...v4.4.1) #### What's Changed - Add a section about hidden files by [@​joshmgross](https://redirect.github.com/joshmgross) in [https://github.com/actions/upload-artifact/pull/607](https://redirect.github.com/actions/upload-artifact/pull/607) - Add workflow file for publishing releases to immutable action package by [@​Jcambass](https://redirect.github.com/Jcambass) in [https://github.com/actions/upload-artifact/pull/621](https://redirect.github.com/actions/upload-artifact/pull/621) - Update [@​actions/artifact](https://redirect.github.com/actions/artifact) to latest version, includes symlink and timeout fixes by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/625](https://redirect.github.com/actions/upload-artifact/pull/625) #### New Contributors - [@​Jcambass](https://redirect.github.com/Jcambass) made their first contribution in [https://github.com/actions/upload-artifact/pull/621](https://redirect.github.com/actions/upload-artifact/pull/621) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.4.0...v4.4.1 ### [`v4.4.0`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.4.0) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.6...v4.4.0) #### Notice: Breaking Changes ⚠️ We will no longer include hidden files and folders by default in the `upload-artifact` action of this version. This reduces the risk that credentials are accidentally uploaded into artifacts. Customers who need to continue to upload these files can use a new option, `include-hidden-files`, to continue to do so. See ["Notice of upcoming deprecations and breaking changes in GitHub Actions runners"](https://github.blog/changelog/2024-08-19-notice-of-upcoming-deprecations-and-breaking-changes-in-github-actions-runners/) changelog and [this issue](https://redirect.github.com/actions/upload-artifact/issues/602) for more details. #### What's Changed - Exclude hidden files by default by [@​joshmgross](https://redirect.github.com/joshmgross) in [https://github.com/actions/upload-artifact/pull/598](https://redirect.github.com/actions/upload-artifact/pull/598) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.3.6...v4.4.0 ### [`v4.3.6`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.6) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.5...v4.3.6) #### What's Changed - Revert to [@​actions/artifact](https://redirect.github.com/actions/artifact) 2.1.8 by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/594](https://redirect.github.com/actions/upload-artifact/pull/594) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.3.6 ### [`v4.3.5`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.5) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.4...v4.3.5) #### What's Changed - Bump [@​actions/artifact](https://redirect.github.com/actions/artifact) to v2.1.9 by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/588](https://redirect.github.com/actions/upload-artifact/pull/588) - Fixed artifact upload chunk timeout logic [#​1774](https://redirect.github.com/actions/toolkit/pull/1774) - Use lazy stream to prevent issues with open file limits [#​1771](https://redirect.github.com/actions/toolkit/pull/1771) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.3.4...v4.3.5 ### [`v4.3.4`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.4) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.3...v4.3.4) #### What's Changed - Update [@​actions/artifact](https://redirect.github.com/actions/artifact) version, bump dependencies by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/584](https://redirect.github.com/actions/upload-artifact/pull/584) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.3.3...v4.3.4 ### [`v4.3.3`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.3) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.2...v4.3.3) #### What's Changed - updating `@actions/artifact` dependency to v2.1.6 by [@​eggyhead](https://redirect.github.com/eggyhead) in [https://github.com/actions/upload-artifact/pull/565](https://redirect.github.com/actions/upload-artifact/pull/565) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.3.2...v4.3.3 ### [`v4.3.2`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.2) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.1...v4.3.2) #### What's Changed - Update release-new-action-version.yml by [@​konradpabjan](https://redirect.github.com/konradpabjan) in [https://github.com/actions/upload-artifact/pull/516](https://redirect.github.com/actions/upload-artifact/pull/516) - Minor fix to the migration readme by [@​andrewakim](https://redirect.github.com/andrewakim) in [https://github.com/actions/upload-artifact/pull/523](https://redirect.github.com/actions/upload-artifact/pull/523) - Update readme with v3/v2/v1 deprecation notice by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/561](https://redirect.github.com/actions/upload-artifact/pull/561) - updating `@actions/artifact` dependency to v2.1.5 and `@actions/core` to v1.0.1 by [@​eggyhead](https://redirect.github.com/eggyhead) in [https://github.com/actions/upload-artifact/pull/562](https://redirect.github.com/actions/upload-artifact/pull/562) #### New Contributors - [@​andrewakim](https://redirect.github.com/andrewakim) made their first contribution in [https://github.com/actions/upload-artifact/pull/523](https://redirect.github.com/actions/upload-artifact/pull/523) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4.3.1...v4.3.2 ### [`v4.3.1`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.1) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.3.0...v4.3.1) - Bump [@​actions/artifacts](https://redirect.github.com/actions/artifacts) to latest version to include [updated GHES host check](https://redirect.github.com/actions/toolkit/pull/1648) ### [`v4.3.0`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.3.0) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.2.0...v4.3.0) #### What's Changed - Reorganize upload code in prep for merge logic & add more tests by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/504](https://redirect.github.com/actions/upload-artifact/pull/504) - Add sub-action to merge artifacts by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/505](https://redirect.github.com/actions/upload-artifact/pull/505) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.3.0 ### [`v4.2.0`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.2.0) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4.1.0...v4.2.0) #### What's Changed - Ability to overwrite an Artifact by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/501](https://redirect.github.com/actions/upload-artifact/pull/501) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.2.0 ### [`v4.1.0`](https://redirect.github.com/actions/upload-artifact/releases/tag/v4.1.0) [Compare Source](https://redirect.github.com/actions/upload-artifact/compare/v4...v4.1.0) #### What's Changed - Add migrations docs by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/482](https://redirect.github.com/actions/upload-artifact/pull/482) - Update README.md by [@​samuelwine](https://redirect.github.com/samuelwine) in [https://github.com/actions/upload-artifact/pull/492](https://redirect.github.com/actions/upload-artifact/pull/492) - Support artifact-url output by [@​konradpabjan](https://redirect.github.com/konradpabjan) in [https://github.com/actions/upload-artifact/pull/496](https://redirect.github.com/actions/upload-artifact/pull/496) - Update readme to reflect new 500 artifact per job limit by [@​robherley](https://redirect.github.com/robherley) in [https://github.com/actions/upload-artifact/pull/497](https://redirect.github.com/actions/upload-artifact/pull/497) #### New Contributors - [@​samuelwine](https://redirect.github.com/samuelwine) made their first contribution in [https://github.com/actions/upload-artifact/pull/492](https://redirect.github.com/actions/upload-artifact/pull/492) **Full Changelog**: https://github.com/actions/upload-artifact/compare/v4...v4.1.0 </details> --- ### Configuration 📅 **Schedule**: Branch creation - "before 4am on Monday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/astral-sh/ruff). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS4yMjcuMyIsInVwZGF0ZWRJblZlciI6IjM5LjIyNy4zIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6WyJpbnRlcm5hbCJdfQ==--> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
481 lines
17 KiB
YAML
481 lines
17 KiB
YAML
# Build ruff on all platforms.
|
|
#
|
|
# Generates both wheels (for PyPI) and archived binaries (for GitHub releases).
|
|
#
|
|
# Assumed to run as a subworkflow of .github/workflows/release.yml; specifically, as a local
|
|
# artifacts job within `cargo-dist`.
|
|
name: "Build binaries"
|
|
|
|
on:
|
|
workflow_call:
|
|
inputs:
|
|
plan:
|
|
required: true
|
|
type: string
|
|
pull_request:
|
|
paths:
|
|
# When we change pyproject.toml, we want to ensure that the maturin builds still work.
|
|
- pyproject.toml
|
|
# And when we change this workflow itself...
|
|
- .github/workflows/build-binaries.yml
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
permissions: {}
|
|
|
|
env:
|
|
PACKAGE_NAME: ruff
|
|
MODULE_NAME: ruff
|
|
PYTHON_VERSION: "3.13"
|
|
CARGO_INCREMENTAL: 0
|
|
CARGO_NET_RETRY: 10
|
|
CARGO_TERM_COLOR: always
|
|
RUSTUP_MAX_RETRIES: 10
|
|
|
|
jobs:
|
|
sdist:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build sdist"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
command: sdist
|
|
args: --out dist
|
|
- name: "Test sdist"
|
|
run: |
|
|
pip install dist/"${PACKAGE_NAME}"-*.tar.gz --force-reinstall
|
|
"${MODULE_NAME}" --help
|
|
python -m "${MODULE_NAME}" --help
|
|
- name: "Upload sdist"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-sdist
|
|
path: dist
|
|
|
|
macos-x86_64:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: macos-14
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
architecture: x64
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels - x86_64"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: x86_64
|
|
args: --release --locked --out dist
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-macos-x86_64
|
|
path: dist
|
|
- name: "Archive binary"
|
|
run: |
|
|
TARGET=x86_64-apple-darwin
|
|
ARCHIVE_NAME=ruff-$TARGET
|
|
ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz
|
|
|
|
mkdir -p $ARCHIVE_NAME
|
|
cp target/$TARGET/release/ruff $ARCHIVE_NAME/ruff
|
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-macos-x86_64
|
|
path: |
|
|
*.tar.gz
|
|
*.sha256
|
|
|
|
macos-aarch64:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: macos-14
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
architecture: arm64
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels - aarch64"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: aarch64
|
|
args: --release --locked --out dist
|
|
- name: "Test wheel - aarch64"
|
|
run: |
|
|
pip install dist/"${PACKAGE_NAME}"-*.whl --force-reinstall
|
|
ruff --help
|
|
python -m ruff --help
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-aarch64-apple-darwin
|
|
path: dist
|
|
- name: "Archive binary"
|
|
run: |
|
|
TARGET=aarch64-apple-darwin
|
|
ARCHIVE_NAME=ruff-$TARGET
|
|
ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz
|
|
|
|
mkdir -p $ARCHIVE_NAME
|
|
cp target/$TARGET/release/ruff $ARCHIVE_NAME/ruff
|
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-aarch64-apple-darwin
|
|
path: |
|
|
*.tar.gz
|
|
*.sha256
|
|
|
|
windows:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: windows-latest
|
|
strategy:
|
|
matrix:
|
|
platform:
|
|
- target: x86_64-pc-windows-msvc
|
|
arch: x64
|
|
- target: i686-pc-windows-msvc
|
|
arch: x86
|
|
- target: aarch64-pc-windows-msvc
|
|
arch: x64
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
architecture: ${{ matrix.platform.arch }}
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: ${{ matrix.platform.target }}
|
|
args: --release --locked --out dist
|
|
env:
|
|
# aarch64 build fails, see https://github.com/PyO3/maturin/issues/2110
|
|
XWIN_VERSION: 16
|
|
- name: "Test wheel"
|
|
if: ${{ !startsWith(matrix.platform.target, 'aarch64') }}
|
|
shell: bash
|
|
run: |
|
|
python -m pip install dist/"${PACKAGE_NAME}"-*.whl --force-reinstall
|
|
"${MODULE_NAME}" --help
|
|
python -m "${MODULE_NAME}" --help
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-${{ matrix.platform.target }}
|
|
path: dist
|
|
- name: "Archive binary"
|
|
shell: bash
|
|
run: |
|
|
ARCHIVE_FILE=ruff-${{ matrix.platform.target }}.zip
|
|
7z a $ARCHIVE_FILE ./target/${{ matrix.platform.target }}/release/ruff.exe
|
|
sha256sum $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-${{ matrix.platform.target }}
|
|
path: |
|
|
*.zip
|
|
*.sha256
|
|
|
|
linux:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
target:
|
|
- x86_64-unknown-linux-gnu
|
|
- i686-unknown-linux-gnu
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
architecture: x64
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: ${{ matrix.target }}
|
|
manylinux: auto
|
|
args: --release --locked --out dist
|
|
- name: "Test wheel"
|
|
if: ${{ startsWith(matrix.target, 'x86_64') }}
|
|
run: |
|
|
pip install dist/"${PACKAGE_NAME}"-*.whl --force-reinstall
|
|
"${MODULE_NAME}" --help
|
|
python -m "${MODULE_NAME}" --help
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-${{ matrix.target }}
|
|
path: dist
|
|
- name: "Archive binary"
|
|
shell: bash
|
|
run: |
|
|
set -euo pipefail
|
|
|
|
TARGET=${{ matrix.target }}
|
|
ARCHIVE_NAME=ruff-$TARGET
|
|
ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz
|
|
|
|
mkdir -p $ARCHIVE_NAME
|
|
cp target/$TARGET/release/ruff $ARCHIVE_NAME/ruff
|
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-${{ matrix.target }}
|
|
path: |
|
|
*.tar.gz
|
|
*.sha256
|
|
|
|
linux-cross:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
platform:
|
|
- target: aarch64-unknown-linux-gnu
|
|
arch: aarch64
|
|
# see https://github.com/astral-sh/ruff/issues/3791
|
|
# and https://github.com/gnzlbg/jemallocator/issues/170#issuecomment-1503228963
|
|
maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16
|
|
- target: armv7-unknown-linux-gnueabihf
|
|
arch: armv7
|
|
- target: s390x-unknown-linux-gnu
|
|
arch: s390x
|
|
- target: powerpc64le-unknown-linux-gnu
|
|
arch: ppc64le
|
|
# see https://github.com/astral-sh/ruff/issues/10073
|
|
maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16
|
|
- target: powerpc64-unknown-linux-gnu
|
|
arch: ppc64
|
|
# see https://github.com/astral-sh/ruff/issues/10073
|
|
maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16
|
|
- target: arm-unknown-linux-musleabihf
|
|
arch: arm
|
|
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: ${{ matrix.platform.target }}
|
|
manylinux: auto
|
|
docker-options: ${{ matrix.platform.maturin_docker_options }}
|
|
args: --release --locked --out dist
|
|
- uses: uraimo/run-on-arch-action@ac33288c3728ca72563c97b8b88dda5a65a84448 # v2
|
|
if: ${{ matrix.platform.arch != 'ppc64' && matrix.platform.arch != 'ppc64le'}}
|
|
name: Test wheel
|
|
with:
|
|
arch: ${{ matrix.platform.arch == 'arm' && 'armv6' || matrix.platform.arch }}
|
|
distro: ${{ matrix.platform.arch == 'arm' && 'bullseye' || 'ubuntu20.04' }}
|
|
githubToken: ${{ github.token }}
|
|
install: |
|
|
apt-get update
|
|
apt-get install -y --no-install-recommends python3 python3-pip
|
|
pip3 install -U pip
|
|
run: |
|
|
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
|
ruff --help
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-${{ matrix.platform.target }}
|
|
path: dist
|
|
- name: "Archive binary"
|
|
shell: bash
|
|
run: |
|
|
set -euo pipefail
|
|
|
|
TARGET=${{ matrix.platform.target }}
|
|
ARCHIVE_NAME=ruff-$TARGET
|
|
ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz
|
|
|
|
mkdir -p $ARCHIVE_NAME
|
|
cp target/$TARGET/release/ruff $ARCHIVE_NAME/ruff
|
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-${{ matrix.platform.target }}
|
|
path: |
|
|
*.tar.gz
|
|
*.sha256
|
|
|
|
musllinux:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
target:
|
|
- x86_64-unknown-linux-musl
|
|
- i686-unknown-linux-musl
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
architecture: x64
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: ${{ matrix.target }}
|
|
manylinux: musllinux_1_2
|
|
args: --release --locked --out dist
|
|
- name: "Test wheel"
|
|
if: matrix.target == 'x86_64-unknown-linux-musl'
|
|
uses: addnab/docker-run-action@v3
|
|
with:
|
|
image: alpine:latest
|
|
options: -v ${{ github.workspace }}:/io -w /io
|
|
run: |
|
|
apk add python3
|
|
python -m venv .venv
|
|
.venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
|
.venv/bin/${{ env.MODULE_NAME }} --help
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-${{ matrix.target }}
|
|
path: dist
|
|
- name: "Archive binary"
|
|
shell: bash
|
|
run: |
|
|
set -euo pipefail
|
|
|
|
TARGET=${{ matrix.target }}
|
|
ARCHIVE_NAME=ruff-$TARGET
|
|
ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz
|
|
|
|
mkdir -p $ARCHIVE_NAME
|
|
cp target/$TARGET/release/ruff $ARCHIVE_NAME/ruff
|
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-${{ matrix.target }}
|
|
path: |
|
|
*.tar.gz
|
|
*.sha256
|
|
|
|
musllinux-cross:
|
|
if: ${{ !contains(github.event.pull_request.labels.*.name, 'no-build') }}
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
platform:
|
|
- target: aarch64-unknown-linux-musl
|
|
arch: aarch64
|
|
maturin_docker_options: -e JEMALLOC_SYS_WITH_LG_PAGE=16
|
|
- target: armv7-unknown-linux-musleabihf
|
|
arch: armv7
|
|
|
|
steps:
|
|
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
|
|
with:
|
|
submodules: recursive
|
|
persist-credentials: false
|
|
- uses: actions/setup-python@8d9ed9ac5c53483de85588cdf95a591a75ab9f55 # v5.5.0
|
|
with:
|
|
python-version: ${{ env.PYTHON_VERSION }}
|
|
- name: "Prep README.md"
|
|
run: python scripts/transform_readme.py --target pypi
|
|
- name: "Build wheels"
|
|
uses: PyO3/maturin-action@44479ae1b6b1a57f561e03add8832e62c185eb17 # v1.48.1
|
|
with:
|
|
target: ${{ matrix.platform.target }}
|
|
manylinux: musllinux_1_2
|
|
args: --release --locked --out dist
|
|
docker-options: ${{ matrix.platform.maturin_docker_options }}
|
|
- uses: uraimo/run-on-arch-action@ac33288c3728ca72563c97b8b88dda5a65a84448 # v2
|
|
name: Test wheel
|
|
with:
|
|
arch: ${{ matrix.platform.arch }}
|
|
distro: alpine_latest
|
|
githubToken: ${{ github.token }}
|
|
install: |
|
|
apk add python3
|
|
run: |
|
|
python -m venv .venv
|
|
.venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
|
.venv/bin/${{ env.MODULE_NAME }} --help
|
|
- name: "Upload wheels"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: wheels-${{ matrix.platform.target }}
|
|
path: dist
|
|
- name: "Archive binary"
|
|
shell: bash
|
|
run: |
|
|
set -euo pipefail
|
|
|
|
TARGET=${{ matrix.platform.target }}
|
|
ARCHIVE_NAME=ruff-$TARGET
|
|
ARCHIVE_FILE=$ARCHIVE_NAME.tar.gz
|
|
|
|
mkdir -p $ARCHIVE_NAME
|
|
cp target/$TARGET/release/ruff $ARCHIVE_NAME/ruff
|
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
|
- name: "Upload binary"
|
|
uses: actions/upload-artifact@ea165f8d65b6e75b540449e92b4886f43607fa02 # v4.6.2
|
|
with:
|
|
name: artifacts-${{ matrix.platform.target }}
|
|
path: |
|
|
*.tar.gz
|
|
*.sha256
|