[Scummvm-git-logs] scummvm master -> e542099638887cd47fb37fb4f65323dbe7bedf82

rvanlaar roland at rolandvanlaar.nl
Mon Aug 23 15:26:52 UTC 2021


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
e542099638 DEVTOOLS: COMPANION: Fix dir globbing


Commit: e542099638887cd47fb37fb4f65323dbe7bedf82
    https://github.com/scummvm/scummvm/commit/e542099638887cd47fb37fb4f65323dbe7bedf82
Author: Roland van Laar (roland at rolandvanlaar.nl)
Date: 2021-08-23T17:16:15+02:00

Commit Message:
DEVTOOLS: COMPANION: Fix dir globbing

There were two problems:

- glob pattern only found directories:
    Now it returns both directories and files.

- top level dir was included in the punyencoding

Changed paths:
    devtools/dumper-companion.py


diff --git a/devtools/dumper-companion.py b/devtools/dumper-companion.py
index 044b4e80cf..bfc5e15d40 100755
--- a/devtools/dumper-companion.py
+++ b/devtools/dumper-companion.py
@@ -292,7 +292,9 @@ def punyencode_dir(directory: Path, verbose: bool = False) -> int:
     """
     files: List[Path] = []
     dirs: List[Path] = []
-    for item in directory.glob("**"):
+    path_glob = directory.glob("**/*")
+    next(path_glob) # Don't punyencode the root directory
+    for item in path_glob:
         if item.is_file():
             files.append(item)
         if item.is_dir():




More information about the Scummvm-git-logs mailing list