aboutsummaryrefslogtreecommitdiff
path: root/kde-modules/KDEFrameworkCompilerSettings.cmake
diff options
context:
space:
mode:
authorAhmad Samir <a.samirh78@gmail.com>2022-03-17 12:57:00 +0200
committerAhmad Samir <a.samirh78@gmail.com>2022-03-17 12:57:00 +0200
commit7cb3191ccb1dc24ff21a9e41ec30d52f420c98e6 (patch)
tree3be27b80e7d784256f16e51643990dab45b22089 /kde-modules/KDEFrameworkCompilerSettings.cmake
parente96843828d8c3bbd8d63f196cac780108598b1b9 (diff)
downloadextra-cmake-modules-7cb3191ccb1dc24ff21a9e41ec30d52f420c98e6.tar.gz
extra-cmake-modules-7cb3191ccb1dc24ff21a9e41ec30d52f420c98e6.tar.bz2
KDEClangFormat: se the same source file extensions in clang-format script and target
Previously the clang-format.sh git hook script didn't specify the file extensions to format; however it looks like with recent(?) clang-format versions 'git clang-format' will consider .json files if such files were changed by a commit, which makes the script fail, see: https://invent.kde.org/frameworks/extra-cmake-modules/-/merge_requests/254 Sepcify the file extensions by passing --extensions to 'git clang-format' command. Also add ".hpp" to the file extensions we format, and use the same list of file extensions everywhere.
Diffstat (limited to 'kde-modules/KDEFrameworkCompilerSettings.cmake')
-rw-r--r--kde-modules/KDEFrameworkCompilerSettings.cmake2
1 files changed, 1 insertions, 1 deletions
diff --git a/kde-modules/KDEFrameworkCompilerSettings.cmake b/kde-modules/KDEFrameworkCompilerSettings.cmake
index 3eb640ef..fa31a93b 100644
--- a/kde-modules/KDEFrameworkCompilerSettings.cmake
+++ b/kde-modules/KDEFrameworkCompilerSettings.cmake
@@ -64,7 +64,7 @@ add_definitions(
# add clang-format target
include(KDEClangFormat)
-file(GLOB_RECURSE ALL_CLANG_FORMAT_SOURCE_FILES *.cpp *.h *.c)
+file(GLOB_RECURSE ALL_CLANG_FORMAT_SOURCE_FILES *.cpp *.h *.hpp *.c)
kde_clang_format(${ALL_CLANG_FORMAT_SOURCE_FILES})
# add the metainfo platform check