diff options
author | Alexander Lohnau <alexander.lohnau@gmx.de> | 2021-01-11 20:39:06 +0100 |
---|---|---|
committer | David Faure <faure@kde.org> | 2021-01-16 08:50:13 +0000 |
commit | 45edd1b17051def13c157cba3b01fac53364149c (patch) | |
tree | ec6644d3b24cf272ae1a6e87e9720fe409de2985 /kde-modules/kde-git-commit-hooks/pre-commit.in | |
parent | b7affc18e5dad21fe29451cd9ecff54e40e42d79 (diff) | |
download | extra-cmake-modules-45edd1b17051def13c157cba3b01fac53364149c.tar.gz extra-cmake-modules-45edd1b17051def13c157cba3b01fac53364149c.tar.bz2 |
Add cmake function to configure git pre-commit hooks
This will allow us to force QS checks before
the developer commits a change. Currently only
clang-format is supported, but as on #plasma and
https://phabricator.kde.org/T11214 discussed we
might want to add different formatters.
By making the checks configurable we are flexible
and can easily extend it.
Diffstat (limited to 'kde-modules/kde-git-commit-hooks/pre-commit.in')
-rw-r--r-- | kde-modules/kde-git-commit-hooks/pre-commit.in | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/kde-modules/kde-git-commit-hooks/pre-commit.in b/kde-modules/kde-git-commit-hooks/pre-commit.in new file mode 100644 index 00000000..36cdfd5d --- /dev/null +++ b/kde-modules/kde-git-commit-hooks/pre-commit.in @@ -0,0 +1,3 @@ +#!/usr/bin/env bash + +${CLANG_FORMAT_SCRIPT} |