]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Scripts/FormatDosFiles.py
BaseTools:"--exclude" don't apply if parameter ends with separator
[mirror_edk2.git] / BaseTools / Scripts / FormatDosFiles.py
index 3150bef3c2015a706d3aadb40d265fe2873aaa64..e119334dede7778d01cb98506e199fe8a49dde34 100644 (file)
@@ -53,6 +53,7 @@ def FormatFilesInDir(DirPath, ExtList, Args):
             FileNames[:] = [f for f in FileNames if f not in Args.Exclude]\r
             Continue = False\r
             for Path in Args.Exclude:\r
+                Path = Path.strip('\\').strip('/')\r
                 if not os.path.isdir(Path) and not os.path.isfile(Path):\r
                     Path = os.path.join(ExcludeDir, Path)\r
                 if os.path.isdir(Path) and Path.endswith(DirPath):\r