mirror of
https://github.com/panda3d/panda3d.git
synced 2025-10-03 10:22:45 -04:00
deploy-ng: Fix so whole directories can be skipped instead of skipping each file in a directory
This commit is contained in:
parent
09eb22b61e
commit
14fa7c18cc
@ -271,7 +271,7 @@ class build_apps(distutils.core.Command):
|
||||
def dir_has_files(directory):
|
||||
files = [
|
||||
i for i in os.listdir(directory)
|
||||
if not check_pattern(os.path.join(directory, i))
|
||||
if check_pattern(os.path.join(directory, i))
|
||||
]
|
||||
return bool(files)
|
||||
|
||||
@ -308,7 +308,9 @@ class build_apps(distutils.core.Command):
|
||||
d = os.path.join(dst, item)
|
||||
if os.path.isfile(s):
|
||||
copy_file(s, d)
|
||||
elif dir_has_files(s):
|
||||
elif not dir_has_files(s):
|
||||
print("skipping directory", os.path.normpath(s))
|
||||
else:
|
||||
copy_dir(s, d)
|
||||
|
||||
for path in self.copy_paths:
|
||||
|
Loading…
x
Reference in New Issue
Block a user