Re: [EXTERNAL] Re: [edk2-devel] [PATCH v1 1/1] Pytool: SpellCheck: Defer path expansion in cspell parameters


Kun Qin
 

Thanks for the review. Updated patch has been sent here: https://edk2.groups.io/g/devel/message/76553.

Please let me know if any other feedbacks.

Regards,
Kun

On 06/15/2021 09:20, Bret Barkelew wrote:
Reviewed-by: Bret Barkelew <bret.barkelew@...>
- Bret
*From: *Sean Brogan <mailto:spbrogan@...>
*Sent: *Tuesday, June 15, 2021 9:00 AM
*To: *devel@edk2.groups.io <mailto:devel@edk2.groups.io>; kuqin12@... <mailto:kuqin12@...>
*Cc: *Sean Brogan <mailto:sean.brogan@...>; Bret Barkelew <mailto:Bret.Barkelew@...>; Kinney, Michael D <mailto:michael.d.kinney@...>; Liming Gao <mailto:gaoliming@...>
*Subject: *[EXTERNAL] Re: [edk2-devel] [PATCH v1 1/1] Pytool: SpellCheck: Defer path expansion in cspell parameters
Please update the signed-off-by to include yours.
Reviewed-by: Sean Brogan <sean.brogan@...>
Thanks
Sean
On 6/11/2021 10:04 PM, Kun Qin wrote:
> From: Sean Brogan <sean.brogan@...>
>
> REF:
https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugzilla.tianocore.org%2Fshow_bug.cgi%3Fid%3D3454&;data=04%7C01%7CBret.Barkelew%40microsoft.com%7C436f445e3f774d2549b608d930169d05%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637593696216659744%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&amp;sdata=pJiLG4bZ8gYR0MjDuNTmuT3NgRjq%2FZRMnTi1sT67VqM%3D&amp;reserved=0 <https://nam06.safelinks.protection.outlook.com/?url=https%3A%2F%2Fbugzilla.tianocore.org%2Fshow_bug.cgi%3Fid%3D3454&;data=04%7C01%7CBret.Barkelew%40microsoft.com%7C436f445e3f774d2549b608d930169d05%7C72f988bf86f141af91ab2d7cd011db47%7C1%7C0%7C637593696216659744%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&amp;sdata=pJiLG4bZ8gYR0MjDuNTmuT3NgRjq%2FZRMnTi1sT67VqM%3D&amp;reserved=0>
>
> 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 <sean.brogan@...>
> Cc: Bret Barkelew <Bret.Barkelew@...>
> Cc: Michael D Kinney <michael.d.kinney@...>
> Cc: Liming Gao <gaoliming@...>
>
> Signed-off-by: Sean Brogan <sean.brogan@...>
> ---
>   .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 43365441b91c..97b240ef747c 100644
> --- a/.pytool/Plugin/SpellCheck/SpellCheck.py
> +++ b/.pytool/Plugin/SpellCheck/SpellCheck.py
> @@ -133,7 +133,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(
>

Join devel@edk2.groups.io to automatically receive all group messages.