diff --git a/zsh/.zshrc b/zsh/.zshrc index 5972733..3bd0af9 100644 --- a/zsh/.zshrc +++ b/zsh/.zshrc @@ -20,10 +20,9 @@ if [[ -f ~/.zsh/.shared_config ]] ; then fi function update_dotfiles () { - cd ~/dotfiles - fetch=$(git fetch) - if [[ -n "$fetch" ]]; then - git pull 2>& 1 > /dev/null + cd ~/dotfiles || return + if git fetch --dry-run | grep -q .; then + git pull > /dev/null 2>&1 fi }