Skip to content

Commit

Permalink
Merge pull request ohmyzsh#3095 from robbyrussell/revert-1504-master
Browse files Browse the repository at this point in the history
Revert "Exit early from git plugin if not in git repo." due to ohmyzsh#3082
  • Loading branch information
robbyrussell committed Sep 4, 2014
2 parents a8ef111 + 5e25913 commit ffe8ce5
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions plugins/git/git.plugin.zsh
Expand Up @@ -125,14 +125,12 @@ alias gsd='git svn dcommit'
# Usage example: git pull origin $(current_branch)
#
function current_branch() {
if [ ! -d .git ]; then return; fi
ref=$(git symbolic-ref HEAD 2> /dev/null) || \
ref=$(git rev-parse --short HEAD 2> /dev/null) || return
echo ${ref#refs/heads/}
}

function current_repository() {
if [ ! -d .git ]; then return; fi
ref=$(git symbolic-ref HEAD 2> /dev/null) || \
ref=$(git rev-parse --short HEAD 2> /dev/null) || return
echo $(git remote -v | cut -d':' -f 2)
Expand Down

0 comments on commit ffe8ce5

Please sign in to comment.