mcrapet/plowshare

Errors when using a run-before/run-after script that has a space in its path name

Closed this issue · 2 comments

Hello,

when invoking plowdown with --run-before or --run-after and the script to be run resides in a directory containing a space in its name, plowdown can't find that script and shows some errors.

For example, running plowdown --run-before=./run_before.sh [...] from within the folder folder 123 results in:

Retrieving list [...]
/usr/local/bin/plowdown: line 809: declare: `123/./run_before.sh': not a valid identifier
Starting download [...]
/usr/local/bin/plowdown: line 292: /Users/ghost/folder: No such file or directory
Pre-processing script exited with status 127, continue anyway
File URL: [...]
Filename: [...]

Running the command from the parent directory, using --run-before='folder 123/run_before.sh', doesn't make any difference.

I suppose it has something to do with Bash's word splitting but cannot find the error as $PRE_COMMAND seems to be properly quoted.

Hi,
commit 6be6671 is supposed to fix this.
It's not in last version 2.1.6, only in GIT for now.

Now released officially in 2.1.7.