diff options
author | Parabola git <git@parabola.nu> | 2016-07-08 00:55:19 +0000 |
---|---|---|
committer | Parabola git <git@parabola.nu> | 2016-07-08 00:55:19 +0000 |
commit | 3eb16d93bf95b2a7d40fb1607622cab1e2f4b81e (patch) | |
tree | 6b971400f294f1b5b5bfd34ef93924715bdd7c75 /.config/git/hooks/run-parts.sh | |
parent | 4fe7bac236d7c1895271bf15bdb9dda1253ec230 (diff) |
redo hooks infrastructure (yay git 2.9 core.hooksPath)
Diffstat (limited to '.config/git/hooks/run-parts.sh')
-rwxr-xr-x | .config/git/hooks/run-parts.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/.config/git/hooks/run-parts.sh b/.config/git/hooks/run-parts.sh new file mode 100755 index 0000000..c42173a --- /dev/null +++ b/.config/git/hooks/run-parts.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash + +if [[ -d "$0.d" ]]; then + run-parts "${@/#/--arg=}" -- "$0.d" +fi +file="$GIT_DIR/hooks/${0##*/}" +if [[ -x "$file" && -f "$file" ]]; then + "$file" +fi |