From fe825e405b5bd9358718c2e5f1b0ba20b7d7cb9a Mon Sep 17 00:00:00 2001 Message-Id: In-Reply-To: References: From: =?UTF-8?q?J=C3=B6rg=20Sommer?= Date: Mon, 8 May 2017 18:05:54 +0200 Subject: [PATCH 2/2] run-help-git: Print alias and skip shell commands Print the definition of the git-alias like run-help does for shell aliases. Git handles an alias starting with ! as a shell command. Hence, there's no man-page for it. --- Functions/Misc/run-help-git | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Functions/Misc/run-help-git b/Functions/Misc/run-help-git index ce94d0d02..3c8e6a150 100644 --- a/Functions/Misc/run-help-git +++ b/Functions/Misc/run-help-git @@ -3,6 +3,8 @@ if [ $# -eq 0 ]; then else local al if al=$(git config --get "alias.$1"); then + builtin print -r "${run_help_orig_cmd:-git} $1 is a git-alias for $al" + [[ $al == !* ]] && return 1=${al%% *} fi man git-$1 -- 2.11.0