rcm icon indicating copy to clipboard operation
rcm copied to clipboard

mkrc: `eval: Syntax error: "(" unexpected` on filenames with `(`

Open agentydragon opened this issue 1 year ago • 1 comments

I'm trying to commit into rcm some files from OrcaSlicer config which contain ( in the filename. I'm getting "/usr/bin/rcup: 1: eval: Syntax error: "(" unexpected runningmkrc *` from the directory.

I think it happens because the dests_and_srcs="$(eval "lsrc $LS_ARGS")" does not properly escape the braces. Shell tries to execute eval my(filename)test and that would trigger spawning a sub-shell to execute filename. Seems like an escaping problem but I'm not sure what's the right way to fix it.

For my use-case I'm luckily able to work around by making the filename not have ('s.

agentydragon avatar Sep 02 '24 03:09 agentydragon

You can try the fix suggested in this issue's comment and report back if it works.

mat-m avatar Dec 14 '24 17:12 mat-m