From 297238b739fd51f03ab9b3ffcc6c644daa4a1401 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20D=C4=99bski?= Date: Fri, 11 Mar 2016 16:59:40 +0100 Subject: [PATCH] lib: hide git_prompt_status when hide-status is set Closes #4912 Closes #5137 Closes #8071 --- lib/git.zsh | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/git.zsh b/lib/git.zsh index ffc7c01a1..b3b25f802 100644 --- a/lib/git.zsh +++ b/lib/git.zsh @@ -151,6 +151,8 @@ function git_prompt_long_sha() { function git_prompt_status() { emulate -L zsh + [[ "$(__git_prompt_git config --get oh-my-zsh.hide-status 2>/dev/null)" = 1 ]] && return + local INDEX STATUS INDEX=$(__git_prompt_git status --porcelain -b 2> /dev/null) || return 0 STATUS=""