Skip to content

Commit

Permalink
fix(ci): separate artifacts for release and debugging (#297) (#298)
Browse files Browse the repository at this point in the history
  • Loading branch information
behnazh authored Aug 26, 2022
1 parent 55b8d91 commit ffe5028
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 6 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -98,13 +98,21 @@ jobs:
echo "Digest of artifacts is $DIGEST."
# Set the computed sha digest as the output of this job.
echo "::set-output name=artifacts-sha256::$DIGEST"
- name: Upload the package artifact
# For now only generate artifacts for the specified OS and Python version in env variables.
# Currently reusable workflows do not support setting strategy property from the caller workflow.
if: matrix.os == env.ARTIFACT_OS && matrix.python == env.ARTIFACT_PYTHON
# For now only generate artifacts for the specified OS and Python version in env variables.
# Currently reusable workflows do not support setting strategy property from the caller workflow.
- name: Upload the package artifact for debugging
if: inputs.is_release_build == false && matrix.python == '3.10' && matrix.os == 'ubuntu-latest'
uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0
with:
name: artifact-${{ matrix.os }}-python-${{ matrix.python }}
name: debug-artifact-${{ matrix.os }}-python-${{ matrix.python }}
path: dist
if-no-files-found: error
retention-days: 1
- name: Upload the package artifact for release
if: inputs.is_release_build == true && matrix.python == '3.10' && matrix.os == 'ubuntu-latest'
uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0
with:
name: release-artifact-${{ matrix.os }}-python-${{ matrix.python }}
path: dist
if-no-files-found: error
retention-days: 5
2 changes: 1 addition & 1 deletion .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ on:
permissions:
contents: read
env:
ARTIFACT_NAME: artifact-ubuntu-latest-python-3.10
ARTIFACT_NAME: release-artifact-ubuntu-latest-python-3.10
# This is the username and email for the user who commits and pushes the release
# commit. In an organisation that should be a dedicated devops account.
USER_NAME: jenstroeger
Expand Down

0 comments on commit ffe5028

Please sign in to comment.