From ae66602ce7d214dbd2e298c1db67a81388755a0a Mon Sep 17 00:00:00 2001 From: Piers Beckley Date: Mon, 17 Oct 2022 10:41:08 +0100 Subject: [PATCH] Allow files with spaces (#12) --- .github/workflows/main.yml | 6 ++++++ entrypoint.sh | 2 +- tests/path with spaces.txt | 1 + 3 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 tests/path with spaces.txt diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 61c045a..3eb8e07 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -17,3 +17,9 @@ jobs: source: "tests/a.txt" target: "test-a.txt" flags: "-f" + - name: copy file with spaces + uses: canastro/copy-file-action@master + with: + source: "tests/path with spaces.txt" + target: "path-without-spaces.txt" + \ No newline at end of file diff --git a/entrypoint.sh b/entrypoint.sh index 495dc4f..8cfc997 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -1,3 +1,3 @@ #!/bin/sh -l -cp $1 $2 $3 \ No newline at end of file +cp $1 "$2" "$3" \ No newline at end of file diff --git a/tests/path with spaces.txt b/tests/path with spaces.txt new file mode 100644 index 0000000..b4937cf --- /dev/null +++ b/tests/path with spaces.txt @@ -0,0 +1 @@ +Test file for copying a file with spaces in its path