mirror of https://github.com/astral-sh/uv
feat: bump actions/{download,upload}-artifact (#1947)
## Summary Closes #1943 Makes sure `build-binaries` and `publish-pypi` workflows are compatible with `actions/{download,upload}-artifact@v4`. In nature, this PR is very similar to the changes in https://github.com/astral-sh/ruff/pull/10105. This PR also updates cargo-dist. ## Test Plan I ran a small non-dry-run [smoke test](https://github.com/samypr100/uv/actions/runs/8027864059) on my own fork CI with only linux builds (for speed) and those jobs seem to work at a glance.
This commit is contained in:
parent
757f8e2f60
commit
df812a181e
|
|
@ -54,9 +54,9 @@ jobs:
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
python -m ${{ env.MODULE_NAME }} --help
|
python -m ${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload sdist"
|
- name: "Upload sdist"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-sdist
|
||||||
path: dist
|
path: dist
|
||||||
|
|
||||||
macos-x86_64:
|
macos-x86_64:
|
||||||
|
|
@ -76,9 +76,9 @@ jobs:
|
||||||
target: x86_64
|
target: x86_64
|
||||||
args: --release --locked --out dist
|
args: --release --locked --out dist
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-macos-x86_64
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
run: |
|
run: |
|
||||||
|
|
@ -91,9 +91,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-macos-x86_64
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -119,9 +119,9 @@ jobs:
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
python -m ${{ env.MODULE_NAME }} --help
|
python -m ${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-aarch64-apple-darwin
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
run: |
|
run: |
|
||||||
|
|
@ -134,9 +134,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-aarch64-apple-darwin
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -172,9 +172,9 @@ jobs:
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
python -m ${{ env.MODULE_NAME }} --help
|
python -m ${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.platform.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -183,9 +183,9 @@ jobs:
|
||||||
7z a $ARCHIVE_FILE ./target/${{ matrix.platform.target }}/release/uv.exe
|
7z a $ARCHIVE_FILE ./target/${{ matrix.platform.target }}/release/uv.exe
|
||||||
sha256sum $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
sha256sum $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.platform.target }}
|
||||||
path: |
|
path: |
|
||||||
*.zip
|
*.zip
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -234,9 +234,9 @@ jobs:
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
python -m ${{ env.MODULE_NAME }} --help
|
python -m ${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -252,9 +252,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.target }}
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -302,9 +302,9 @@ jobs:
|
||||||
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.platform.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -320,9 +320,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.platform.target }}
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -367,9 +367,9 @@ jobs:
|
||||||
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.platform.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -385,9 +385,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.platform.target }}
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -441,9 +441,9 @@ jobs:
|
||||||
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
||||||
${{ env.MODULE_NAME }} --help
|
${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.platform.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -459,9 +459,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.platform.target }}
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -500,9 +500,9 @@ jobs:
|
||||||
.venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
.venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
||||||
.venv/bin/${{ env.MODULE_NAME }} --help
|
.venv/bin/${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -518,9 +518,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.target }}
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
@ -564,9 +564,9 @@ jobs:
|
||||||
.venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
.venv/bin/pip3 install ${{ env.PACKAGE_NAME }} --no-index --find-links dist/ --force-reinstall
|
||||||
.venv/bin/${{ env.MODULE_NAME }} --help
|
.venv/bin/${{ env.MODULE_NAME }} --help
|
||||||
- name: "Upload wheels"
|
- name: "Upload wheels"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
name: wheels-${{ matrix.platform.target }}
|
||||||
path: dist
|
path: dist
|
||||||
- name: "Archive binary"
|
- name: "Archive binary"
|
||||||
shell: bash
|
shell: bash
|
||||||
|
|
@ -582,9 +582,9 @@ jobs:
|
||||||
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
tar czvf $ARCHIVE_FILE $ARCHIVE_NAME
|
||||||
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
shasum -a 256 $ARCHIVE_FILE > $ARCHIVE_FILE.sha256
|
||||||
- name: "Upload binary"
|
- name: "Upload binary"
|
||||||
uses: actions/upload-artifact@v3
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: artifacts
|
name: artifacts-${{ matrix.platform.target }}
|
||||||
path: |
|
path: |
|
||||||
*.tar.gz
|
*.tar.gz
|
||||||
*.sha256
|
*.sha256
|
||||||
|
|
|
||||||
|
|
@ -21,10 +21,11 @@ jobs:
|
||||||
# For PyPI's trusted publishing.
|
# For PyPI's trusted publishing.
|
||||||
id-token: write
|
id-token: write
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/download-artifact@v3
|
- uses: actions/download-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: wheels
|
pattern: wheels-*
|
||||||
path: wheels
|
path: wheels
|
||||||
|
merge-multiple: true
|
||||||
- name: Publish to PyPi
|
- name: Publish to PyPi
|
||||||
uses: pypa/gh-action-pypi-publish@release/v1
|
uses: pypa/gh-action-pypi-publish@release/v1
|
||||||
with:
|
with:
|
||||||
|
|
|
||||||
|
|
@ -65,7 +65,7 @@ jobs:
|
||||||
# we specify bash to get pipefail; it guards against the `curl` command
|
# we specify bash to get pipefail; it guards against the `curl` command
|
||||||
# failing. otherwise `sh` won't catch that `curl` returned non-0
|
# failing. otherwise `sh` won't catch that `curl` returned non-0
|
||||||
shell: bash
|
shell: bash
|
||||||
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.11.0/cargo-dist-installer.sh | sh"
|
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.11.1/cargo-dist-installer.sh | sh"
|
||||||
# sure would be cool if github gave us proper conditionals...
|
# sure would be cool if github gave us proper conditionals...
|
||||||
# so here's a doubly-nested ternary-via-truthiness to try to provide the best possible
|
# so here's a doubly-nested ternary-via-truthiness to try to provide the best possible
|
||||||
# functionality based on whether this is a pull_request, and whether it's from a fork.
|
# functionality based on whether this is a pull_request, and whether it's from a fork.
|
||||||
|
|
@ -107,7 +107,7 @@ jobs:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
- name: Install cargo-dist
|
- name: Install cargo-dist
|
||||||
shell: bash
|
shell: bash
|
||||||
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.11.0/cargo-dist-installer.sh | sh"
|
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.11.1/cargo-dist-installer.sh | sh"
|
||||||
# Get all the local artifacts for the global tasks to use (for e.g. checksums)
|
# Get all the local artifacts for the global tasks to use (for e.g. checksums)
|
||||||
- name: Fetch local artifacts
|
- name: Fetch local artifacts
|
||||||
uses: actions/download-artifact@v4
|
uses: actions/download-artifact@v4
|
||||||
|
|
@ -151,7 +151,7 @@ jobs:
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
- name: Install cargo-dist
|
- name: Install cargo-dist
|
||||||
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.11.0/cargo-dist-installer.sh | sh"
|
run: "curl --proto '=https' --tlsv1.2 -LsSf https://github.com/axodotdev/cargo-dist/releases/download/v0.11.1/cargo-dist-installer.sh | sh"
|
||||||
# Fetch artifacts from scratch-storage
|
# Fetch artifacts from scratch-storage
|
||||||
- name: Fetch artifacts
|
- name: Fetch artifacts
|
||||||
uses: actions/download-artifact@v4
|
uses: actions/download-artifact@v4
|
||||||
|
|
|
||||||
|
|
@ -158,7 +158,7 @@ lto = "thin"
|
||||||
# Config for 'cargo dist'
|
# Config for 'cargo dist'
|
||||||
[workspace.metadata.dist]
|
[workspace.metadata.dist]
|
||||||
# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax)
|
# The preferred cargo-dist version to use in CI (Cargo.toml SemVer syntax)
|
||||||
cargo-dist-version = "0.11.0"
|
cargo-dist-version = "0.11.1"
|
||||||
# CI backends to support
|
# CI backends to support
|
||||||
ci = ["github"]
|
ci = ["github"]
|
||||||
# The installers to generate for each app
|
# The installers to generate for each app
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue