clang-format: update latest spec and reformat
Copy the latest format file from the docs repository and apply.
Change-Id: I4113bd60a6817c8fdfad541c58e0910035a663ca
Signed-off-by: Patrick Williams <patrick@stwcx.xyz>
diff --git a/.clang-format b/.clang-format
index a75a2c2..e5530e6 100644
--- a/.clang-format
+++ b/.clang-format
@@ -104,7 +104,7 @@
PenaltyBreakString: 1000
PenaltyBreakTemplateDeclaration: 10
PenaltyExcessCharacter: 1000000
-PenaltyReturnTypeOnItsOwnLine: 60
+PenaltyReturnTypeOnItsOwnLine: 150
PenaltyIndentedWhitespace: 1
PointerAlignment: Left
QualifierAlignment: Left
diff --git a/activation.hpp b/activation.hpp
index 31f7023..4f8e2c6 100644
--- a/activation.hpp
+++ b/activation.hpp
@@ -184,8 +184,8 @@
*
* @return Success or exception thrown
*/
- RequestedActivations
- requestedActivation(RequestedActivations value) override;
+ RequestedActivations requestedActivation(
+ RequestedActivations value) override;
/**
* @brief subscribe to the systemd signals
diff --git a/image_verify.cpp b/image_verify.cpp
index b2c7edd..bdbc9af 100644
--- a/image_verify.cpp
+++ b/image_verify.cpp
@@ -279,8 +279,8 @@
return true;
}
-inline EVP_PKEY_Ptr
- Signature::createPublicRSA(const std::filesystem::path& publicKey)
+inline EVP_PKEY_Ptr Signature::createPublicRSA(
+ const std::filesystem::path& publicKey)
{
auto size = std::filesystem::file_size(publicKey);
diff --git a/static/item_updater_static.cpp b/static/item_updater_static.cpp
index 5fbe5e0..b931681 100644
--- a/static/item_updater_static.cpp
+++ b/static/item_updater_static.cpp
@@ -350,8 +350,8 @@
return true;
}
-void
- ItemUpdaterStatic::updateFunctionalAssociation(const std::string& versionId)
+void ItemUpdaterStatic::updateFunctionalAssociation(
+ const std::string& versionId)
{
functionalVersionId = versionId;
ItemUpdater::updateFunctionalAssociation(versionId);
diff --git a/ubi/activation_ubi.hpp b/ubi/activation_ubi.hpp
index 26d4209..fb8a68d 100644
--- a/ubi/activation_ubi.hpp
+++ b/ubi/activation_ubi.hpp
@@ -52,8 +52,8 @@
*/
Activations activation(Activations value) override;
- RequestedActivations
- requestedActivation(RequestedActivations value) override;
+ RequestedActivations requestedActivation(
+ RequestedActivations value) override;
private:
/** @brief Tracks whether the read-only & read-write volumes have been
diff --git a/version.cpp b/version.cpp
index 99ca119..6a826f9 100644
--- a/version.cpp
+++ b/version.cpp
@@ -97,8 +97,8 @@
return keys;
}
-std::pair<std::string, std::string>
- Version::getVersions(const std::string& versionPart)
+std::pair<std::string, std::string> Version::getVersions(
+ const std::string& versionPart)
{
// versionPart contains strings like below:
// open-power-romulus-v2.2-rc1-48-g268344f-dirty
diff --git a/version.hpp b/version.hpp
index 5c166bb..9c3cb56 100644
--- a/version.hpp
+++ b/version.hpp
@@ -139,8 +139,8 @@
*
* @return The pair contains the version and extended version.
**/
- static std::pair<std::string, std::string>
- getVersions(const std::string& versionPart);
+ static std::pair<std::string, std::string> getVersions(
+ const std::string& versionPart);
/**
* @brief Calculate the version id from the version string.