clang-tidy: Enable bugprone-unchecked-optional-access
Enable bugprone-unchecked-optional-access to detect the case that it
accesses std::optional without checking empty.
See https://gerrit.openbmc.org/c/openbmc/docs/+/78034 for details.
Signed-off-by: Lei YU <yulei.sh@bytedance.com>
Change-Id: I2127eb6d68e78f2282ab982f1708d039e1652ed9
diff --git a/.clang-tidy b/.clang-tidy
new file mode 100644
index 0000000..4b6eca0
--- /dev/null
+++ b/.clang-tidy
@@ -0,0 +1,7 @@
+Checks: '
+ -*,
+ bugprone-unchecked-optional-access,
+ readability-identifier-naming
+'
+WarningsAsErrors: '*'
+HeaderFilterRegex: '(?!^subprojects).*'