Index: litsupport/run_under.py =================================================================== --- litsupport/run_under.py +++ litsupport/run_under.py @@ -3,7 +3,19 @@ def mutateCommandLine(context, commandline): - return context.config.run_under + " " + commandline + cmd = shellcommand.parse(commandline) + run_under_cmd = shellcommand.parse(context.config.run_under) + + if (run_under_cmd.stdin is not None or + run_under_cmd.stdout is not None or + run_under_cmd.stderr is not None or + run_under_cmd.workdir is not None or + run_under_cmd.envvars): + raise Exception("invalid run_under argument!") + + cmd.wrap(run_under_cmd.executable, run_under_cmd.arguments) + + return cmd.toCommandline() def mutatePlan(context, plan):