clang-format: update latest spec and reformat
Copy the latest format file from the docs repository and apply.
Also: remove .clang-tidy
Change-Id: Ia8751e357e58d46666d4f5065df3e4a83d6df32f
Signed-off-by: George Liu <liuxiwei@ieisystem.com>
diff --git a/.clang-format b/.clang-format
index f387595..84647d0 100644
--- a/.clang-format
+++ b/.clang-format
@@ -41,12 +41,14 @@
SplitEmptyRecord: false
SplitEmptyNamespace: false
BreakAfterAttributes: Never
+BreakAfterReturnType: Automatic
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Custom
BreakBeforeTernaryOperators: true
BreakConstructorInitializers: AfterColon
BreakInheritanceList: AfterColon
BreakStringLiterals: false
+BreakTemplateDeclarations: Yes
ColumnLimit: 80
CommentPragmas: '^ IWYU pragma:'
CompactNamespaces: false
diff --git a/.clang-tidy b/.clang-tidy
deleted file mode 100644
index b14abca..0000000
--- a/.clang-tidy
+++ /dev/null
@@ -1,23 +0,0 @@
-Checks: '
--*,
-
-# Categories
--bugprone-*,
--cert-*,
--clang-analyzer-*,
--cppcoreguidelines-*,
--misc-*,
--modernize-*,
-modernize-use-nullptr,
--performance-*,
--readability-*,
-'
-
-# Treat all warnings as errors
-WarningsAsErrors: '*'
-
-# Apply checks to all files
-HeaderFilterRegex: '.*'
-
-# Disable automatic formatting
-FormatStyle: none
diff --git a/meson.options b/meson.options
index 0b231c8..c6a5ee9 100644
--- a/meson.options
+++ b/meson.options
@@ -1,5 +1,6 @@
option(
- 'BIOS_OBJPATH', type: 'string',
+ 'BIOS_OBJPATH',
+ type: 'string',
value: '/xyz/openbmc_project/software/bios_active',
- description: 'The BIOS software Dbus object path'
+ description: 'The BIOS software Dbus object path',
)
diff --git a/src/meson.build b/src/meson.build
index 3f64ef2..8120234 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -1,30 +1,23 @@
-configure_file(output: 'config.h',
- configuration: cdata,
-)
+configure_file(output: 'config.h', configuration: cdata)
src_inc = include_directories('.')
so_version = '0.1.0'
-sources = [
- 'asset_info.cpp',
- 'firmware_version.cpp',
- 'power.cpp',
- 'utils.cpp',
-]
+sources = ['asset_info.cpp', 'firmware_version.cpp', 'power.cpp', 'utils.cpp']
deps = [
- phosphor_dbus_interfaces_dep,
- phosphor_logging_dep,
- ipmid_dep,
- sdbusplus_dep,
+ phosphor_dbus_interfaces_dep,
+ phosphor_logging_dep,
+ ipmid_dep,
+ sdbusplus_dep,
]
shared_library(
- 'iei-ipmi-oem',
- sources,
- dependencies: deps,
- version: so_version,
- install: true,
- install_dir: get_option('libdir') / 'ipmid-providers'
+ 'iei-ipmi-oem',
+ sources,
+ dependencies: deps,
+ version: so_version,
+ install: true,
+ install_dir: get_option('libdir') / 'ipmid-providers',
)