1
0
mirror of https://git.decapod.one/brethil/dotfiles synced 2024-11-23 20:11:31 +01:00

Fixed autoupdater script

This commit is contained in:
bretello 2017-08-08 10:52:00 +02:00
parent cf0b5ee0f1
commit 2c0f91f5c2
2 changed files with 5 additions and 5 deletions

View File

@ -1,5 +1,5 @@
# Check for update, set DISABLE_UPDATE_PROMPT=yes to disable the prompt and automatically update # Check for update, set DISABLE_UPDATE_PROMPT=yes to disable the prompt and automatically update
env ZSH=$ZSH DISABLE_UPDATE_PROMPT=$DISABLE_UPDATE_PROMPT zsh -f $DOTFILES/check_for_update.sh env ZSH=$ZSH DISABLE_UPDATE_PROMPT=$DISABLE_UPDATE_PROMPT DOTFILES=$DOTFILES zsh -f $DOTFILES/check_for_update.sh
# oh-my-zsh plugins (some of these have to be installed by running install.sh or install_zsh_plugins, found in install.sh) # oh-my-zsh plugins (some of these have to be installed by running install.sh or install_zsh_plugins, found in install.sh)
shared_plugins=(git alias-tips sudo common-aliases fast-syntax-highlighting zsh-autosuggestions colored-man-pages zsh-navigation-tools zsh_reload ) shared_plugins=(git alias-tips sudo common-aliases fast-syntax-highlighting zsh-autosuggestions colored-man-pages zsh-navigation-tools zsh_reload )

View File

@ -26,13 +26,13 @@ if [[ -z "$epoch_target" ]]; then
fi fi
# Cancel upgrade if the current user doesn't have write permissions for the # Cancel upgrade if the current user doesn't have write permissions for the
# oh-my-zsh directory. # dotfiles directory.
[[ -w "$ZSH" ]] || return 0 [[ -w "$DOTFILES" ]] || return 0
# Cancel upgrade if git is unavailable on the system # Cancel upgrade if git is unavailable on the system
whence git >/dev/null || return 0 whence git >/dev/null || return 0
if mkdir "$DOTFILES/log/update.lock" 2>/dev/null; then if mkdir "$DOTFILES/update.lock" 2>/dev/null; then
if [ -f ~/.dotfiles-update ]; then if [ -f ~/.dotfiles-update ]; then
. ~/.dotfiles-update . ~/.dotfiles-update
@ -59,5 +59,5 @@ if mkdir "$DOTFILES/log/update.lock" 2>/dev/null; then
_update_dotfiles_update _update_dotfiles_update
fi fi
rmdir $DOTFILES/log/update.lock rmdir $DOTFILES/update.lock
fi fi