diff --git a/Changelog b/Changelog index 9a7e88e2..8c794fa4 100644 --- a/Changelog +++ b/Changelog @@ -1,3 +1,7 @@ +* Tue Nov 27 2007 Jesse Keating +- Enable TMPDIR again so that anconda-runtime working files +go to the working dir. + * Thu Nov 22 2007 Jesse Keating - Print a usage if no options are passed - Correct a man page typo diff --git a/pypungi/__init__.py b/pypungi/__init__.py index cd20515e..f9adfdfa 100644 --- a/pypungi/__init__.py +++ b/pypungi/__init__.py @@ -52,13 +52,13 @@ class PungiBase(object): filename=logfile) -def _doRunCommand(command, logger, rundir='/tmp', output=subprocess.PIPE, error=subprocess.PIPE): +def _doRunCommand(command, logger, rundir='/tmp', output=subprocess.PIPE, error=subprocess.PIPE, env=None): """Run a command and log the output. Error out if we get something on stderr""" logger.info("Running %s" % ' '.join(command)) - p1 = subprocess.Popen(command, cwd=rundir, stdout=output, stderr=error, universal_newlines=True) + p1 = subprocess.Popen(command, cwd=rundir, stdout=output, stderr=error, universal_newlines=True, env=env) (out, err) = p1.communicate() if out: diff --git a/pypungi/pungi.py b/pypungi/pungi.py index 2cc210a1..3f47f25d 100755 --- a/pypungi/pungi.py +++ b/pypungi/pungi.py @@ -137,7 +137,7 @@ class Pungi(pypungi.PungiBase): buildinstall.append(self.topdir) # run the command - pypungi._doRunCommand(buildinstall, self.logger) + pypungi._doRunCommand(buildinstall, self.logger, env={"TMPDIR": self.workdir}) # write out the tree data for snake self.writeinfo('tree: %s' % self.mkrelative(self.topdir))