nrnrnr / noweb

The noweb tool for literate programming
BSD 2-Clause "Simplified" License
255 stars 27 forks source link

Shell scripts don't handle filenames with spaces #8

Open nrnrnr opened 6 years ago

nrnrnr commented 6 years ago

At least noweave, and probably others, don't handle filenames with spaces.

I'm reluctant to introduce a dependency on bash, but I would need some help to figure out how to manage arrays in a POSIX standard shell.

dbosk commented 6 years ago

StackOverflow to the rescue ;-) This GitHub repo that the third answer links to seems promising (PoC of arrays in POSIX shells).

nrnrnr commented 6 years ago

Clever. Missing here is the ability to turn the array elements into an argument vector, as in the ksh/bash extension "${a[@]}".

I may have to resort to some form of eval.

I'm unlikely to fix this issue, but I would welcome a PR.