Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Upgrade upload-artifact and download-artifact actions to v4 #78

Merged
merged 1 commit into from
Jan 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/app-build-verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ jobs:
- name: Get Briefcase Packages
# Briefcase will build and package itself in a previous step in its CI
if: endsWith(inputs.repository, 'briefcase')
uses: actions/download-artifact@v3.0.2
uses: actions/download-artifact@v4.1.0
with:
name: packages-briefcase
path: dist
Expand Down Expand Up @@ -382,7 +382,7 @@ jobs:
briefcase package web static

- name: Upload Failure Logs
uses: actions/upload-artifact@v3.1.3
uses: actions/upload-artifact@v4.0.0
if: failure()
with:
name: build-failure-logs-${{ inputs.runner-os }}-${{ inputs.framework }}-${{ inputs.python-version }}-${{ inputs.target-platform }}-${{ inputs.target-format }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/app-create-verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ jobs:
- name: Get Briefcase Package
# Briefcase will build and package itself in a previous step in its CI
if: endsWith(github.repository, 'briefcase')
uses: actions/download-artifact@v3.0.2
uses: actions/download-artifact@v4.1.0
with:
name: packages-briefcase
path: dist
Expand Down Expand Up @@ -121,8 +121,8 @@ jobs:
assert pyproject_toml.is_file()
pprint(toml.load(pyproject_toml))

- name: Upload failure logs
uses: actions/upload-artifact@v3.1.3
- name: Upload Failure Logs
uses: actions/upload-artifact@v4.0.0
if: failure()
with:
name: build-failure-logs-${{ inputs.runner-os }}-${{ inputs.framework }}-${{ inputs.python-version }}
Expand Down
18 changes: 12 additions & 6 deletions .github/workflows/python-package-create.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,13 @@ on:
type: string
outputs:
artifact-name:
description: "Name of the uploaded artifact; use for artifact retrieval."
description: >
Name of the uploaded artifact; use for artifact retrieval.
Note that if a `build-subdirectory` is specified, this value will be the "base" of the artifact name.
For instance, if the `core` subdirectory of Toga is being built, then this value will be `packages-toga`
but the name of the uploaded artifact will be `packages-toga-core`.
Therefore, when a `build-subdirectory` is used with this workflow, the `pattern` input for the
`actions\download-artifact` should be used to specify `${ needs.package.outputs.artifact-name }-*`.
value: ${{ jobs.package.outputs.artifact-name }}

env:
Expand All @@ -51,7 +57,7 @@ jobs:
artifact-name: packages-${{ steps.package.outputs.name }}
steps:

- name: Determine Package name
- name: Determine Package Name
id: package
run: echo "name=$(basename '${{ inputs.repository }}')" >> ${GITHUB_OUTPUT}

Expand All @@ -76,17 +82,17 @@ jobs:
- name: Install tox
run: python -m pip install ${{ inputs.tox-source }}

- name: Build wheels
- name: Build Wheels
if: inputs.build-subdirectory == ''
run: tox -e package${{ inputs.tox-factors }}

- name: Build wheels from subdirectory
- name: Build Wheels from Subdirectory
if: inputs.build-subdirectory != ''
run: tox -e package${{ inputs.tox-factors }} -- ${{ inputs.build-subdirectory }}

- name: Upload Package
uses: actions/upload-artifact@v3.1.3
uses: actions/upload-artifact@v4.0.0
with:
name: packages-${{ steps.package.outputs.name }}
name: packages-${{ steps.package.outputs.name }}${{ inputs.build-subdirectory && format('-{0}', inputs.build-subdirectory) || '' }}
path: ${{ inputs.distribution-path }}
if-no-files-found: error
Loading