mirror of https://github.com/acidanthera/audk.git
BaseTools:"--exclude" don't apply if parameter ends with separator
BZ:https://bugzilla.tianocore.org/show_bug.cgi?id=1944 FormatDosFiles.py Intel\ServerSiliconPkg --exclude Library\SimRegisters\ Its parameter "Library\SimRegisters\" ends with '\' but I can't seem to get it to exclude the SimRegisters directory This patch is going to fix this issue Cc: Liming Gao <liming.gao@intel.com> Cc: Bob Feng <bob.c.feng@intel.com> Signed-off-by: Zhiju.Fan <zhijux.fan@intel.com>
This commit is contained in:
parent
c70fef962e
commit
6da405ebf6
|
@ -53,6 +53,7 @@ def FormatFilesInDir(DirPath, ExtList, Args):
|
|||
FileNames[:] = [f for f in FileNames if f not in Args.Exclude]
|
||||
Continue = False
|
||||
for Path in Args.Exclude:
|
||||
Path = Path.strip('\\').strip('/')
|
||||
if not os.path.isdir(Path) and not os.path.isfile(Path):
|
||||
Path = os.path.join(ExcludeDir, Path)
|
||||
if os.path.isdir(Path) and Path.endswith(DirPath):
|
||||
|
|
Loading…
Reference in New Issue