From bcbe735dc6263bd222b97abda44da330ce4ea79e Mon Sep 17 00:00:00 2001 From: Corvin Mcpherson Date: Tue, 14 Apr 2015 17:10:01 -0400 Subject: [PATCH] Fixed conflict between gcc d compiler and gdc alias --- plugins/git/git.plugin.zsh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/plugins/git/git.plugin.zsh b/plugins/git/git.plugin.zsh index 94a2c4d1a..3d85fed31 100644 --- a/plugins/git/git.plugin.zsh +++ b/plugins/git/git.plugin.zsh @@ -5,8 +5,13 @@ alias gst='git status' compdef _git gst=git-status alias gd='git diff' compdef _git gd=git-diff + +#Dont add alias if gdc (GCC D Compiler) is present +command -v gdc >/dev/null 2>&1 || { alias gdc='git diff --cached' compdef _git gdc=git-diff +} + alias gdt='git diff-tree --no-commit-id --name-only -r' compdef _git gdt=git diff-tree --no-commit-id --name-only -r alias gl='git pull'