mirror of
				https://github.com/dcarrillo/prezto.git
				synced 2025-11-04 00:29:08 +00:00 
			
		
		
		
	Return 1 when a file fails to load
This commit is contained in:
		@@ -8,7 +8,7 @@
 | 
			
		||||
 | 
			
		||||
# Dumb terminals lack support.
 | 
			
		||||
if [[ "$TERM" == 'dumb' ]]; then
 | 
			
		||||
  return
 | 
			
		||||
  return 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
setopt COMPLETE_IN_WORD    # Complete from both ends of a word.
 | 
			
		||||
 
 | 
			
		||||
							
								
								
									
										6
									
								
								init.zsh
									
									
									
									
									
								
							
							
						
						
									
										6
									
								
								init.zsh
									
									
									
									
									
								
							@@ -53,8 +53,6 @@ autoload -Uz zmv
 | 
			
		||||
 | 
			
		||||
# Source plugins defined in ~/.zshrc.
 | 
			
		||||
for plugin in "$plugins[@]"; do
 | 
			
		||||
  zstyle ":omz:plugin:$plugin" enable 'yes'
 | 
			
		||||
 | 
			
		||||
  if [[ ! -d "${0:h}/plugins/$plugin" ]]; then
 | 
			
		||||
    print "omz: no such plugin: $plugin" >&2
 | 
			
		||||
  fi
 | 
			
		||||
@@ -62,6 +60,10 @@ for plugin in "$plugins[@]"; do
 | 
			
		||||
  if [[ -f "${0:h}/plugins/$plugin/init.zsh" ]]; then
 | 
			
		||||
    source "${0:h}/plugins/$plugin/init.zsh"
 | 
			
		||||
  fi
 | 
			
		||||
 | 
			
		||||
  if (( $? == 0 )); then
 | 
			
		||||
    zstyle ":omz:plugin:$plugin" enable 'yes'
 | 
			
		||||
  fi
 | 
			
		||||
done
 | 
			
		||||
unset plugin plugins
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -7,7 +7,7 @@
 | 
			
		||||
 | 
			
		||||
# Dumb terminals lack support.
 | 
			
		||||
if [[ "$TERM" == 'dumb' ]]; then
 | 
			
		||||
  return
 | 
			
		||||
  return 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
# The default styles.
 | 
			
		||||
@@ -65,7 +65,7 @@ keyinfo=(
 | 
			
		||||
for key in "$keyinfo[@]"; do
 | 
			
		||||
  if [[ -z "$key" ]]; then
 | 
			
		||||
    print "omz: one or more keys are non-bindable" >&2
 | 
			
		||||
    return
 | 
			
		||||
    return 1
 | 
			
		||||
  fi
 | 
			
		||||
done
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
@@ -7,7 +7,7 @@
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
if (( ! $+commands[gpg-agent] )); then
 | 
			
		||||
  return
 | 
			
		||||
  return 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
_gpg_env="$HOME/.gnupg/gpg-agent.env"
 | 
			
		||||
 
 | 
			
		||||
@@ -21,7 +21,7 @@
 | 
			
		||||
#
 | 
			
		||||
 | 
			
		||||
if (( ! $+commands[ssh-agent] )); then
 | 
			
		||||
  return
 | 
			
		||||
  return 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
_ssh_agent_env="${HOME}/.ssh/environment-${HOST}"
 | 
			
		||||
 
 | 
			
		||||
@@ -8,7 +8,7 @@
 | 
			
		||||
 | 
			
		||||
# Dumb terminals lack support.
 | 
			
		||||
if [[ "$TERM" == 'dumb' ]]; then
 | 
			
		||||
  return
 | 
			
		||||
  return 1
 | 
			
		||||
fi
 | 
			
		||||
 | 
			
		||||
# Set the GNU Screen window number.
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user