]> SALOME platform Git repositories - tools/sat.git/commitdiff
Salome HOME
filter .git and .svn directories in .tgz sources. See https://codev-tuleap.cea.fr...
authorSPN Salome - CEA <support-salome@cea.fr>
Wed, 28 Jun 2017 09:32:23 +0000 (11:32 +0200)
committerSPN Salome - CEA <support-salome@cea.fr>
Wed, 28 Jun 2017 09:32:23 +0000 (11:32 +0200)
commands/package.py

index 5b18d13e3a9b75064cdc767d44246b30c1b8df65..6a6862e8bdc79739ded490a0f9b37adf91eb80e5 100644 (file)
@@ -747,7 +747,9 @@ def make_archive(prod_name, prod_info, where):
     path_targz_prod = os.path.join(where, prod_name + ".tgz")
     tar_prod = tarfile.open(path_targz_prod, mode='w:gz')
     local_path = prod_info.source_dir
-    tar_prod.add(local_path, arcname=prod_name)
+    tar_prod.add(local_path,
+                 arcname=prod_name,
+                 exclude=exclude_VCS_and_extensions)
     tar_prod.close()
     return path_targz_prod       
 
@@ -1302,7 +1304,6 @@ def run(args, runner, logger):
         tar = tarfile.open(path_targz, mode='w:gz')
         
         # get the filtering function if needed
-        filter_function = None
         filter_function = exclude_VCS_and_extensions
 
         # Add the files to the tarfile object