From f47c4676dd1a532b22a059cd036918abd6b0dd11 Mon Sep 17 00:00:00 2001 From: Sean Brogan Date: Wed, 16 Jun 2021 00:53:57 +0800 Subject: [PATCH] Pytool: SpellCheck: Defer path expansion in cspell parameters REF: https://bugzilla.tianocore.org/show_bug.cgi?id=3454 On Linux the shell expands the wildcard paths and causes multiple files to be missed. This change adds additional quotes to defer expansion in order to bring parity in cspell result. Cc: Sean Brogan Cc: Bret Barkelew Cc: Michael D Kinney Cc: Liming Gao Signed-off-by: Sean Brogan Signed-off-by: Kun Qin Reviewed-by: Sean Brogan Reviewed-by: Bret Barkelew Reviewed-by: Liming Gao --- .pytool/Plugin/SpellCheck/SpellCheck.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.pytool/Plugin/SpellCheck/SpellCheck.py b/.pytool/Plugin/SpellCheck/SpellCheck.py index 9ad57632a6..05c471d91b 100644 --- a/.pytool/Plugin/SpellCheck/SpellCheck.py +++ b/.pytool/Plugin/SpellCheck/SpellCheck.py @@ -134,7 +134,8 @@ class SpellCheck(ICiBuildPlugin): # relpath = os.path.relpath(abs_pkg_path) cpsell_paths = " ".join( - [f"{relpath}/**/{x}" for x in package_relative_paths_to_spell_check]) + # Double quote each path to defer expansion to cspell parameters + [f'"{relpath}/**/{x}"' for x in package_relative_paths_to_spell_check]) # Make the config file config_file_path = os.path.join(