Skip to content

Commit

Permalink
Wrap lines and automatically unzip artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
tstellar committed Jul 19, 2024
1 parent 9ad18ab commit b4896b4
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
5 changes: 0 additions & 5 deletions .github/workflows/issue-write.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,11 +32,6 @@ jobs:
run-id: ${{ github.event.workflow_run.id }}
artifact-name: workflow-args

- name: Unpack Artifact
if: steps.download-artifact.outputs.artifact-id != ''
run: |
unzip ${{ steps.download-artifact.outputs.filename }}
- name: 'Comment on PR'
if: steps.download-artifact.outputs.artifact-id != ''
uses: actions/github-script@v3
Expand Down
17 changes: 14 additions & 3 deletions .github/workflows/unprivileged-download-artifact/action.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
name: Unprivileged Download Artifact
description: Download artifacts from another workflow run without using an access token.
description: >-
Download artifacts from another workflow run without using an access token.
inputs:
run-id:
description: The run-id for the workflow run that you want to download the artifact from. If ommited it will download the most recently created artifact from the repo with the artifact-name.
description: >-
The run-id for the workflow run that you want to download the artifact
from. If ommitted it will download the most recently created artifact
from the repo with the artifact-name.
required: false
artifact-name:
desciption: The name of the artifact to download.
Expand All @@ -11,7 +15,9 @@ inputs:

outputs:
filename:
description: "The filename of the downloaded artifact or the empty string if the artifact was not found."
description: >-
The filename of the downloaded artifact or the empty string if the
artifact was not found.
value: ${{ steps.download-artifact.outputs.filename }}
artifact-id:
description: "The id of the artifact being downloaded."
Expand Down Expand Up @@ -68,3 +74,8 @@ runs:
run: |
curl -L -o ${{ inputs.artifact-name }}.zip "${{ steps.artifact-url.outputs.url }}"
echo "filename=${{ inputs.artifact-name }}.zip" >> $GITHUB_OUTPUT
- shell: bash
if: steps.download-artifact.outputs.filename != ''
run: |
unzip ${{ steps.download-artifact.outputs.filename }}

0 comments on commit b4896b4

Please sign in to comment.