1
0
mirror of https://github.com/GNS3/gns3-server synced 2024-11-28 03:08:14 +00:00

Ignore captures during project export

This commit is contained in:
Julien Duponchelle 2016-04-21 17:02:05 +02:00
parent b7a859fa30
commit 637a7326ec
No known key found for this signature in database
GPG Key ID: CE8B29639E07F5E8

View File

@ -529,9 +529,9 @@ class Project:
# topdown allo to modify the list of directory in order to ignore
# directory
for root, dirs, files in os.walk(self._path, topdown=True):
# Remove snapshots
# Remove snapshots and capture
if os.path.split(root)[-1:][0] == "project-files":
dirs[:] = [d for d in dirs if d != "snapshots"]
dirs[:] = [d for d in dirs if d not in ("snapshots", "captures")]
# Ignore log files and OS noise
files = [f for f in files if not f.endswith('_log.txt') and not f.endswith('.log') and f != '.DS_Store']