mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-30 02:44:42 +01:00
Merge branch 'master' of https://github.com/ohmyzsh/ohmyzsh
This commit is contained in:
commit
9a32988974
138 changed files with 1492 additions and 805 deletions
|
|
@ -20,14 +20,16 @@ zstyle -s ':omz:update' mode update_mode || {
|
|||
}
|
||||
|
||||
# Cancel update if:
|
||||
# - the automatic update is disabled.
|
||||
# - the current user doesn't have write permissions nor owns the $ZSH directory.
|
||||
# - the automatic update is disabled
|
||||
# - the current user doesn't have write permissions nor owns the $ZSH directory
|
||||
# - is not run from a tty
|
||||
# - git is unavailable on the system.
|
||||
# - git is unavailable on the system
|
||||
# - $ZSH is not a git repository
|
||||
if [[ "$update_mode" = disabled ]] \
|
||||
|| [[ ! -w "$ZSH" || ! -O "$ZSH" ]] \
|
||||
|| [[ ! -t 1 ]] \
|
||||
|| ! command git --version 2>&1 >/dev/null; then
|
||||
|| ! command git --version 2>&1 >/dev/null \
|
||||
|| (builtin cd -q "$ZSH"; ! command git rev-parse --is-inside-work-tree &>/dev/null); then
|
||||
unset update_mode
|
||||
return
|
||||
fi
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue