Important bugfix. This resets the directory we are in after running the
command given to run_command(). This is the expected behavior, but was
overlooked.
None of the current code relies on this behavior, but it's good to act as
expected, anyway.
Signed-off-by: Ira W. Snyder <devel@irasnyder.com>
assert os.path.isdir (indir) # MUST be a directory!
os.chdir (indir)
- return os.system (cmd)
+ ret = os.system (cmd)
+ os.chdir (pwd)
+ return ret
def full_abspath (p):
return os.path.abspath (os.path.expanduser (p))