[Scons-users] Controlling display of a builder

Carnë Draug carandraug+dev at gmail.com
Mon Oct 19 15:29:22 EDT 2015


On 18 October 2015 at 00:39, Bill Deegan <bill at baddogconsulting.com> wrote:
> So for this command all strings should be quoted?
> Or at least that would do no harm?

On 18 October 2015 at 12:37, William Blevins <wblevins001 at gmail.com> wrote:
> I think he is looking for a way to treat the strings as literals: in the
> words on Linux, be all single quote like?

Simply adding single quotes may not be enough.  For my current user cases
it would.  However, the arguments are regular expressions, not just simple
strings.  Escaping everything properly is not trivial.  For example, /foo'/

This is why I am using subprocess.call().  Because it does not involve the
shell, and therefore I will be sure that args will be passed intact to the
Builder program.

I couldn't find any Builder on SCons that would support this, all of them
seem to boil down to create a string with a shell command or call a python
function.  Or am I missing anything?  Or is there any Builder that properly
escapes everything for the shell?  (I'm kinda reluctant on this last option.
I don't want the shell involved, so it seems odd one should work around it
when it's so simple and common to avoid the shell altogether and pass the
arguments straight to the program)

Carnë


More information about the Scons-users mailing list