public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "VivianNK" <vnowkakeane@linux.microsoft.com>
To: devel@edk2.groups.io
Cc: Sean Brogan <sean.brogan@microsoft.com>,
	Michael Kubacki <mikuback@linux.microsoft.com>,
	Michael D Kinney <michael.d.kinney@intel.com>,
	Liming Gao <gaoliming@byosoft.com.cn>,
	Michael Kubacki <michael.kubacki@microsoft.com>
Subject: [edk2-devel] [PATCH v2 2/7] .pytool: Add cpp support to uncrustify plugin
Date: Wed, 16 Aug 2023 14:15:17 -0700	[thread overview]
Message-ID: <20230816211523.12-3-vnowkakeane@linux.microsoft.com> (raw)
In-Reply-To: <20230816211523.12-1-vnowkakeane@linux.microsoft.com>

Modified the uncrustify config to apply cpp specific formatting rules.
Modified uncrustify check to include *.cpp files.

Cc: Sean Brogan <sean.brogan@microsoft.com> 
Cc: Michael Kubacki <mikuback@linux.microsoft.com> 
Cc: Michael D Kinney <michael.d.kinney@intel.com> 
Cc: Liming Gao <gaoliming@byosoft.com.cn> 
Signed-off-by: Vivian Nowka-Keane <vnowkakeane@linux.microsoft.com>
Reviewed-by: Michael Kubacki <michael.kubacki@microsoft.com>
---
 .pytool/Plugin/UncrustifyCheck/UncrustifyCheck.py | 2 +-
 .pytool/Plugin/UncrustifyCheck/uncrustify.cfg     | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/.pytool/Plugin/UncrustifyCheck/UncrustifyCheck.py b/.pytool/Plugin/UncrustifyCheck/UncrustifyCheck.py
index 8978ffc443bf..17f77b48d954 100644
--- a/.pytool/Plugin/UncrustifyCheck/UncrustifyCheck.py
+++ b/.pytool/Plugin/UncrustifyCheck/UncrustifyCheck.py
@@ -110,7 +110,7 @@ class UncrustifyCheck(ICiBuildPlugin):
     # A package can add any additional paths with "AdditionalIncludePaths"
     # A package can remove any of these paths with "IgnoreStandardPaths"
     #
-    STANDARD_PLUGIN_DEFINED_PATHS = ("*.c", "*.h")
+    STANDARD_PLUGIN_DEFINED_PATHS = ("*.c", "*.h", "*.cpp")
 
     #
     # The Uncrustify application path should set in this environment variable
diff --git a/.pytool/Plugin/UncrustifyCheck/uncrustify.cfg b/.pytool/Plugin/UncrustifyCheck/uncrustify.cfg
index 8506c3333715..d7e86a6e57e6 100644
--- a/.pytool/Plugin/UncrustifyCheck/uncrustify.cfg
+++ b/.pytool/Plugin/UncrustifyCheck/uncrustify.cfg
@@ -215,7 +215,7 @@ indent_braces                   = false
 indent_braces_no_class          = false
 indent_braces_no_func           = true
 indent_braces_no_struct         = false
-indent_class                    = false
+indent_class                    = true
 indent_class_colon              = false
 indent_cmt_with_tabs            = false         # Whether to indent comments that are not at a brace level with tabs on
                                                 # a tabstop. Requires indent_with_tabs=2. If false, will use spaces.
@@ -223,7 +223,7 @@ indent_col1_comment             = true
 indent_col1_multi_string_literal= true
 indent_comma_paren              = true
 indent_else_if                  = true
-indent_extern                   = false
+indent_extern                   = true
 indent_first_bool_expr          = true
 
 indent_func_def_param_paren_pos_threshold = 0
-- 
2.41.0.windows.3



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#107811): https://edk2.groups.io/g/devel/message/107811
Mute This Topic: https://groups.io/mt/100788667/7686176
Group Owner: devel+owner@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [rebecca@openfw.io]
-=-=-=-=-=-=-=-=-=-=-=-



  parent reply	other threads:[~2023-08-16 21:15 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-16 21:15 [edk2-devel] [PATCH v2 0/7] Uncrustify GoogleTest update VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 1/7] .pytool: Set uncrustify check to audit only (temporary) VivianNK
2023-08-16 22:09   ` Michael Kubacki
2023-08-16 21:15 ` VivianNK [this message]
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 3/7] MdeModulePkg: Apply uncrustify formatting to relevant files VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 4/7] MdePkg: " VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 5/7] SecurityPkg: " VivianNK
2023-08-17  2:41   ` Yao, Jiewen
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 6/7] UnitTestFrameworkPkg: " VivianNK
2023-08-16 21:15 ` [edk2-devel] [PATCH v2 7/7] .pytool: Undo uncrustify check change VivianNK
2023-08-16 22:09   ` Michael Kubacki
2023-09-12  1:08 ` 回复: [edk2-devel] [PATCH v2 0/7] Uncrustify GoogleTest update gaoliming via groups.io
2023-09-12 14:42 ` Michael D Kinney
2023-09-27 19:43   ` VivianNK
2023-10-24 20:34     ` VivianNK
2023-10-25 17:11       ` Michael D Kinney
2023-10-25 18:08         ` Michael D Kinney
2023-10-26 21:08           ` VivianNK
2023-10-27  2:41             ` Michael D Kinney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230816211523.12-3-vnowkakeane@linux.microsoft.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox