aboutsummaryrefslogtreecommitdiff
path: root/kde-modules/KDEGitCommitHooks.cmake
AgeCommit message (Collapse)Author
2022-02-04Make clang-format Git hook work in worktrees The Assassin
Otherwise, commits will be rejected because the hook cannot be found from the workdir root dir (there is only one .git directory in a checkout, but commands are run relative to the worktree root dir).
2021-09-20Avoid raising an error for submodule git trees.Damien Caliste
2021-08-16Enable KDEGitCommitHooks on WindowsHannah von Reth
Git on Windows provides bash
2021-04-23Modules docs: move rst docs into bracket commentsFriedrich W. H. Kossebau
CMake >= 3.0 supports bracket comments, and the reStructuredText integration code in sphinx/ext/ecm.py already supports extracting the docs from a bracket comment instead. Editing documentation without leading line comment markers is more simple, e,g. when reflowing text over lines. With ECM meanwhile requiring CMake 3.5 now it is possible to switch (and thus follow also the approach used by cmake itself). NO_CHANGELOG
2021-01-30[KDEGitCommitHooks] Create copy of scripts in source dirAlexander Lohnau
It was reported that in case of containerized setups where the source and build are in different containers the pre-commit script would reference a file which is another container and is consequently not found. To avoid this the script is copied in the source dir and a relative path is defined.
2021-01-30Remove optional parameterAlexander Lohnau
This makes it more difficult to implement the relative paths. It would be nice to have, but if we encounter a scenario where we explicitly need this we can revisit it.
2021-01-20Add detailed explanation for KDEGitCommitHooks checksAlexander Lohnau
2021-01-17Comply with naming conventions for optional parametersAlexander Lohnau
2021-01-16Fix typoDavid Faure
GIT_SILENT
2021-01-16Add cmake function to configure git pre-commit hooksAlexander Lohnau
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.