]> err.no Git - dak/commitdiff
Create temp directory at the preferred location.
authorTorsten Werner <twerner@debian.org>
Thu, 24 Mar 2011 21:43:17 +0000 (22:43 +0100)
committerTorsten Werner <twerner@debian.org>
Thu, 24 Mar 2011 21:43:17 +0000 (22:43 +0100)
Signed-off-by: Torsten Werner <twerner@debian.org>
dak/make_changelog.py
daklib/contents.py
tests/fixtures/dak.conf

index 398c3526a54c4f3721be5b7362afc3769c87a3be..ac5581d02be8ae43a3de98d4145a1ef1a49cb7f3 100755 (executable)
@@ -160,7 +160,7 @@ def display_changes(uploads, index):
         print upload[index]
         prev_upload = upload[0]
 
-def export_files(session, pool, clpool, temppath):
+def export_files(session, pool, clpool):
     """
     Export interesting files from source packages.
     """
@@ -282,7 +282,7 @@ def main():
     if export:
         if cnf.exportpath:
             exportpath = os.path.join(Cnf['Dir::Export'], cnf.exportpath)
-            export_files(session, Cnf['Dir::Pool'], exportpath, Cnf['Dir::TempPath'])
+            export_files(session, Cnf['Dir::Pool'], exportpath)
         else:
             utils.fubar('No changelog export path defined')
     elif binnmu:
index a5950524e274fef14f049f28426ac76da9725528..f3077aab6487eede63f71341d01ede61fec16525 100755 (executable)
@@ -441,7 +441,8 @@ class UnpackedSource(object):
         '''
         The dscfilename is a name of a DSC file that will be extracted.
         '''
-        self.root_directory = os.path.join(mkdtemp(), 'root')
+        temp_directory = mkdtemp(dir = Config()['Dir::TempPath'])
+        self.root_directory = os.path.join(temp_directory, 'root')
         command = ('dpkg-source', '--no-copy', '--no-check', '-q', '-x',
             dscfilename, self.root_directory)
         check_call(command, preexec_fn = subprocess_setup)
index 6f68238da95f913c3b23e4c6f9c95f65ef118bc6..3a728f78c1a0911ae74cb62fbab32b32a5a60d66 100644 (file)
@@ -22,6 +22,7 @@ Dir
 {
   Root "tests/fixtures/ftp/";
   Pool "/srv/ftp-master.debian.org/ftp/pool/";
+  TempPath "/tmp";
 };
 
 DB