Split up actions better.
This commit is contained in:
@@ -24,7 +24,7 @@ inputs:
|
||||
unzipPattern:
|
||||
description: "Pattern of the files to upload from the unzipped artifacts."
|
||||
required: false
|
||||
default: ""
|
||||
default: "*"
|
||||
account:
|
||||
description: "Itch.io account name."
|
||||
required: true
|
||||
@@ -44,7 +44,7 @@ inputs:
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- uses: act/common/gitea/download-previous-artifacts@master
|
||||
- uses: act/common/gitea/download-previous-artifact@master
|
||||
id: download
|
||||
with:
|
||||
workflowPattern: ${{ inputs.workflowPattern }}
|
||||
@@ -52,22 +52,10 @@ runs:
|
||||
password: ${{ inputs.password }}
|
||||
nugetPasswords: ${{ inputs.nugetPasswords || inputs.password }}
|
||||
unzipDir: ${{ inputs.unzipDir }}
|
||||
- name: "Get the file to upload."
|
||||
id: artifacts
|
||||
run: |
|
||||
if [[ -n "${{ inputs.unzipDir }}" ]]; then
|
||||
echo "Using unzipPattern: ${{ inputs.unzipPattern }}"
|
||||
FIRST_DIR=$(echo '${{ steps.download.outputs.downloadedArtifactDirs }}' | tr ',' '\n' | head -n 1)
|
||||
echo "file=$(ls -1 ${FIRST_DIR}/*${{ inputs.unzipPattern }} | head -n 1)" >> "$GITHUB_OUTPUT"
|
||||
else
|
||||
echo "Using first downloaded artifact path"
|
||||
echo "file=$(echo '${{ steps.download.outputs.downloadedArtifactPaths }}' | tr ',' '\n' | head -n 1)" >> "$GITHUB_OUTPUT"
|
||||
fi
|
||||
shell: bash
|
||||
- name: "Copy files to Itch.io."
|
||||
uses: act/common/itchio/butler-push@master
|
||||
with:
|
||||
file: ${{ steps.artifacts.outputs.file }}
|
||||
file: ${{ steps.download.outputs.downloadedArtifactPath }}
|
||||
account: ${{ inputs.account }}
|
||||
project: ${{ inputs.project }}
|
||||
channel: ${{ inputs.channel }}
|
||||
|
||||
Reference in New Issue
Block a user