Allow source to be unquoted

This commit is contained in:
2025-12-13 16:16:49 +09:00
parent 2eaf7b8d5d
commit e6d985b364
+9 -1
View File
@@ -20,6 +20,10 @@ inputs:
source: source:
description: "Which files to copy" description: "Which files to copy"
required: true required: true
quote-source:
description: "Whether to quote the source string"
required: true
default: 'true'
target: target:
description: "Where on the host to copy the files" description: "Where on the host to copy the files"
required: true required: true
@@ -98,7 +102,11 @@ runs:
- name: Transfer files - name: Transfer files
run: | run: |
echo "Transferring files" echo "Transferring files"
rsync ${{ inputs.args }} "${{ inputs.source }}" "targethost:${{ inputs.target }}" if [ "${{ inputs.quote-source }}" = "true" ]; then
rsync ${{ inputs.args }} "${{ inputs.source }}" "targethost:${{ inputs.target }}"
else
rsync ${{ inputs.args }} ${{ inputs.source }} "targethost:${{ inputs.target }}"
fi
shell: bash shell: bash
- name: Cleanup - name: Cleanup