underscore = _
progress = sys.stderr.write
-# Modified version of the commands.mkarg(x), which always uses
-# double quotes (since Windows can't handle the single quotes:
-def mkarg(x):
- s = ' "'
- for c in x:
- if c in '\\$"`':
- s = s + '\\'
- s = s + c
- s = s + '"'
- return s
def command_name (cmd):
# Strip all stuf after command,
cmd = re.match ('([\(\)]*)([^\\\ ]*)', cmd).group (2)
return os.path.basename (cmd)
-def subprocess_system (cmd,
- ignore_error=False,
- progress_p=True,
- be_verbose=False,
- log_file=None):
+def system (cmd,
+ ignore_error=False,
+ progress_p=True,
+ be_verbose=False,
+ log_file=None):
+
import subprocess
show_progress= progress_p
return abs (retval)
-
-
-system = subprocess_system
-
-
def strip_extension (f, ext):
(p, e) = os.path.splitext (f)
if e == ext: