Skip to content

Commit 28ccb7f

Browse files
committed
fix: Only copy file if it exists
1 parent 22655a5 commit 28ccb7f

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.github/actions/gh-cache/save/action.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,9 @@ runs:
3333
- name: Copy file to repo
3434
shell: bash
3535
run: |
36-
cp -Rf "${{ inputs.path }}" ".gh-cache-${{ github.run_id }}/${{ inputs.path }}"
36+
if [ -e "${{ inputs.path }}" ]; then
37+
cp -Rf "${{ inputs.path }}" ".gh-cache-${{ github.run_id }}/${{ inputs.path }}"
38+
fi
3739
3840
- name: Commit and push
3941
shell: bash

0 commit comments

Comments
 (0)