diff --git a/.clang-format b/.clang-format
index d43e884..28e3328 100644
--- a/.clang-format
+++ b/.clang-format
@@ -87,7 +87,7 @@
 IndentWrappedFunctionNames: true
 InsertNewlineAtEOF: true
 KeepEmptyLinesAtTheStartOfBlocks: false
-LambdaBodyIndentation: OuterScope
+LambdaBodyIndentation: Signature
 LineEnding: LF
 MacroBlockBegin: ''
 MacroBlockEnd:   ''
@@ -98,13 +98,14 @@
 ObjCSpaceBeforeProtocolList: true
 PackConstructorInitializers: BinPack
 PenaltyBreakAssignment: 25
-PenaltyBreakBeforeFirstCallParameter: 19
+PenaltyBreakBeforeFirstCallParameter: 50
 PenaltyBreakComment: 300
 PenaltyBreakFirstLessLess: 120
 PenaltyBreakString: 1000
+PenaltyBreakTemplateDeclaration: 10
 PenaltyExcessCharacter: 1000000
 PenaltyReturnTypeOnItsOwnLine: 60
-PenaltyIndentedWhitespace: 0
+PenaltyIndentedWhitespace: 1
 PointerAlignment: Left
 QualifierAlignment: Left
 ReferenceAlignment: Left
diff --git a/dump/create_pel.cpp b/dump/create_pel.cpp
index d92e570..90a7ea7 100644
--- a/dump/create_pel.cpp
+++ b/dump/create_pel.cpp
@@ -70,11 +70,11 @@
     }
     try
     {
-        auto service = util::getService(bus, opLoggingInterface,
-                                        loggingObjectPath);
-        auto method = bus.new_method_call(service.c_str(), loggingObjectPath,
-                                          opLoggingInterface,
-                                          "CreatePELWithFFDCFiles");
+        auto service =
+            util::getService(bus, opLoggingInterface, loggingObjectPath);
+        auto method =
+            bus.new_method_call(service.c_str(), loggingObjectPath,
+                                opLoggingInterface, "CreatePELWithFFDCFiles");
         auto level =
             sdbusplus::xyz::openbmc_project::Logging::server::convertForMessage(
                 severity);
diff --git a/dump/dump_collect_main.cpp b/dump/dump_collect_main.cpp
index dc6562b..319309a 100644
--- a/dump/dump_collect_main.cpp
+++ b/dump/dump_collect_main.cpp
@@ -30,9 +30,9 @@
 
     app.add_option("--type, -t", type, "Type of the dump")
         ->required()
-        ->check(CLI::IsMember({SBE_DUMP_TYPE_HARDWARE, SBE_DUMP_TYPE_HOSTBOOT,
-                               SBE_DUMP_TYPE_SBE, SBE_DUMP_TYPE_PERFORMANCE,
-                               SBE_DUMP_TYPE_MSBE}));
+        ->check(CLI::IsMember(
+            {SBE_DUMP_TYPE_HARDWARE, SBE_DUMP_TYPE_HOSTBOOT, SBE_DUMP_TYPE_SBE,
+             SBE_DUMP_TYPE_PERFORMANCE, SBE_DUMP_TYPE_MSBE}));
 
     app.add_option("--id, -i", id, "ID of the dump")->required();
 
diff --git a/dump/dump_monitor.cpp b/dump/dump_monitor.cpp
index 0afe7ca..4a9a357 100644
--- a/dump/dump_monitor.cpp
+++ b/dump/dump_monitor.cpp
@@ -28,8 +28,8 @@
 
     uint32_t dumpId = std::strtoul(dumpIdStr.c_str(), nullptr, 16);
     int dumpType = getDumpTypeFromId(dumpId);
-    std::filesystem::path dumpPath = std::filesystem::path(dumpOutPath) /
-                                     dumpIdStr;
+    std::filesystem::path dumpPath =
+        std::filesystem::path(dumpOutPath) / dumpIdStr;
 
     // Add type, ID, and dump path to args
     args.push_back("-t");
diff --git a/dump/dump_utils.cpp b/dump/dump_utils.cpp
index 18c1d3f..74ec563 100644
--- a/dump/dump_utils.cpp
+++ b/dump/dump_utils.cpp
@@ -23,25 +23,25 @@
         sdbusplus::bus::match::rules::propertiesChanged(
             path, "xyz.openbmc_project.Common.Progress"),
         [&](sdbusplus::message_t& msg) {
-        std::string interface;
-        std::map<std::string, std::variant<std::string, uint8_t>> property;
-        msg.read(interface, property);
+            std::string interface;
+            std::map<std::string, std::variant<std::string, uint8_t>> property;
+            msg.read(interface, property);
 
-        const auto dumpStatus = property.find("Status");
-        if (dumpStatus != property.end())
-        {
-            const std::string* status =
-                std::get_if<std::string>(&(dumpStatus->second));
-            if (status &&
-                *status !=
-                    "xyz.openbmc_project.Common.Progress.OperationStatus.InProgress")
+            const auto dumpStatus = property.find("Status");
+            if (dumpStatus != property.end())
             {
-                lg2::info("Dump status({STATUS}) : path={PATH}", "STATUS",
-                          status->c_str(), "PATH", path.c_str());
-                inProgress = false;
+                const std::string* status =
+                    std::get_if<std::string>(&(dumpStatus->second));
+                if (status &&
+                    *status !=
+                        "xyz.openbmc_project.Common.Progress.OperationStatus.InProgress")
+                {
+                    lg2::info("Dump status({STATUS}) : path={PATH}", "STATUS",
+                              status->c_str(), "PATH", path.c_str());
+                    inProgress = false;
+                }
             }
-        }
-    });
+        });
 
     // Timeout management
     for (uint32_t secondsCount = 0; inProgress && secondsCount < timeout;
@@ -74,8 +74,8 @@
     {
         auto bus = sdbusplus::bus::new_default();
         auto service = getService(bus, interface, path);
-        auto method = bus.new_method_call(service.c_str(), path, interface,
-                                          function);
+        auto method =
+            bus.new_method_call(service.c_str(), path, interface, function);
 
         std::unordered_map<std::string, std::variant<std::string, uint64_t>>
             createParams = {
diff --git a/dump/sbe_dump_collector.cpp b/dump/sbe_dump_collector.cpp
index 0a821a0..b0b3c75 100644
--- a/dump/sbe_dump_collector.cpp
+++ b/dump/sbe_dump_collector.cpp
@@ -142,9 +142,10 @@
 
     for (const auto& [procTarget, ocmbTargets] : targetMap)
     {
-        auto future = std::async(std::launch::async,
-                                 [this, procTarget, ocmbTargets, path, id, type,
-                                  cstate, failingUnit]() {
+        auto future = std::async(std::launch::async, [this, procTarget,
+                                                      ocmbTargets, path, id,
+                                                      type, cstate,
+                                                      failingUnit]() {
             try
             {
                 this->collectDumpFromSBE(procTarget, path, id, type, cstate,
@@ -273,11 +274,9 @@
     return isDumpFailure;
 }
 
-void SbeDumpCollector::collectDumpFromSBE(struct pdbg_target* chip,
-                                          const std::filesystem::path& path,
-                                          uint32_t id, uint8_t type,
-                                          uint8_t clockState,
-                                          uint64_t failingUnit)
+void SbeDumpCollector::collectDumpFromSBE(
+    struct pdbg_target* chip, const std::filesystem::path& path, uint32_t id,
+    uint8_t type, uint8_t clockState, uint64_t failingUnit)
 {
     auto chipPos = pdbg_target_index(chip);
     SBETypes sbeType = getSBEType(chip);
diff --git a/dump/sbe_dump_collector.hpp b/dump/sbe_dump_collector.hpp
index b926203..1cb2348 100644
--- a/dump/sbe_dump_collector.hpp
+++ b/dump/sbe_dump_collector.hpp
@@ -152,10 +152,9 @@
      * @return uint8_t - Returns 1 if fastarray collection is needed, 0
      * otherwise.
      */
-    inline uint8_t checkFastarrayCollectionNeeded(const uint8_t clockState,
-                                                  const uint8_t type,
-                                                  uint64_t failingUnit,
-                                                  const uint8_t chipPos) const
+    inline uint8_t checkFastarrayCollectionNeeded(
+        const uint8_t clockState, const uint8_t type, uint64_t failingUnit,
+        const uint8_t chipPos) const
     {
         using namespace openpower::dump::SBE;
 
diff --git a/watchdog/ffdc_file.cpp b/watchdog/ffdc_file.cpp
index 6aa4a00..62cb1e5 100644
--- a/watchdog/ffdc_file.cpp
+++ b/watchdog/ffdc_file.cpp
@@ -41,8 +41,8 @@
     int fd = open(tempFile.getPath().c_str(), O_RDWR);
     if (fd == -1)
     {
-        throw std::runtime_error{std::string{"Unable to open FFDC file: "} +
-                                 strerror(errno)};
+        throw std::runtime_error{
+            std::string{"Unable to open FFDC file: "} + strerror(errno)};
     }
 
     ssize_t rc = write(fd, calloutData.c_str(), calloutData.size());
diff --git a/watchdog/utils.cpp b/watchdog/utils.cpp
index a66fc8e..ae4a80b 100644
--- a/watchdog/utils.cpp
+++ b/watchdog/utils.cpp
@@ -16,8 +16,8 @@
 TemporaryFile::TemporaryFile()
 {
     // Build template path required by mkstemp()
-    std::string templatePath = fs::temp_directory_path() /
-                               "openpower-debug-collector-XXXXXX";
+    std::string templatePath =
+        fs::temp_directory_path() / "openpower-debug-collector-XXXXXX";
 
     // Generate unique file name, create file, and open it.  The XXXXXX
     // characters are replaced by mkstemp() to make the file name unique.
diff --git a/watchdog/watchdog_dbus.cpp b/watchdog/watchdog_dbus.cpp
index 87aa3f9..c3a797d 100644
--- a/watchdog/watchdog_dbus.cpp
+++ b/watchdog/watchdog_dbus.cpp
@@ -51,16 +51,16 @@
             if (extended == "")
             {
                 // return the method
-                method = bus.new_method_call(service.c_str(), path.c_str(),
-                                             interface.c_str(),
-                                             function.c_str());
+                method =
+                    bus.new_method_call(service.c_str(), path.c_str(),
+                                        interface.c_str(), function.c_str());
             }
             else
             {
                 // return extended method
-                method = bus.new_method_call(service.c_str(), path.c_str(),
-                                             extended.c_str(),
-                                             function.c_str());
+                method =
+                    bus.new_method_call(service.c_str(), path.c_str(),
+                                        extended.c_str(), function.c_str());
             }
 
             rc = RC_SUCCESS;
diff --git a/watchdog/watchdog_handler.cpp b/watchdog/watchdog_handler.cpp
index ec58402..2a2b245 100644
--- a/watchdog/watchdog_handler.cpp
+++ b/watchdog/watchdog_handler.cpp
@@ -81,8 +81,8 @@
             sdbusplus::bus::match::rules::propertiesChanged(
                 path.c_str(), matchInterface.c_str()),
             [&](auto& msg) {
-        return dumpStatusChanged(msg, path, progressStatus);
-    });
+                return dumpStatusChanged(msg, path, progressStatus);
+            });
 
     // wait for dump status to be completed (complete == true)
     // or until timeout interval
