Files
emacs/lisp/magit/git-hooks/post-rewrite
2025-12-25 11:44:13 +01:00

14 lines
316 B
Bash
Executable File

#!/usr/bin/env bash
if [[ "$INSIDE_EMACS" == *magit ]]
then
for arg in "$@"; do args+="\"$arg\""; done
$GIT_EDITOR --eval \
"(magit-run-git-hook '(common-post-commit post-rewrite) ${args[@]})"
fi
if [[ -x "$SHADOWED_GITHOOK_DIRECTORY" ]]
then
"$SHADOWED_GITHOOK_DIRECTORY/$(basename $0)" "$@"
fi