title: zshrc outputing cryptic errors on iterm2 at loading
body: <p>I am a Mac user on osx 10.15.7 (Catalina).
  I recently updated brew and upgraded formulas with it.
  Since then, my terminal has become erratic and prints out these errors:</p>
  <pre><code>_zulu_init_setup_completion:9: compinit: function definition file not found
  /user/path/.zulu/packages/tipz/tipz.zsh:86: add-zsh-hook: function definition file not found
  _zulu_init:48: promptinit: function definition file not found
  _zulu_init:50: command not found: prompt
  /user/path/.zprezto/init.zsh:14: is-at-least: function definition file not found
  prezto: old shell detected, minimum required: 4.3.17
  /user/path/.zshrc:19: promptinit: function definition file not found
  /usr/local/Cellar/zplug/2.4.2/autoload/init.zsh:16: colors: function definition file not found
  polling.zsh:17: add-zsh-hook: function definition file not found
  # the following line is repeated at least 20 times
  __zplug::core::core::get_interfaces:49: regexp-replace: function definition file not found
  __zplug::core::core::prepare:67: compinit: function definition file not found
  [zplug] ERROR: The loading of zplug was discontinued.
  /user/path/.nvm/bash_completion:87: bashcompinit: function definition file not found
  /user/path/.nvm/bash_completion:88: compinit: function definition file not found
  /user/path/.nvm/bash_completion:95: command not found: complete
  /user/path/.zshrc:35: command not found: gcloud
  /user/path/google-cloud-sdk/completion.zsh.inc:1: bashcompinit: function definition file not found
  /user/path/google-cloud-sdk/completion.zsh.inc:4: compinit: function definition file not found
  /user/path/google-cloud-sdk/completion.zsh.inc:37: command not found: complete
  /user/path/google-cloud-sdk/completion.zsh.inc:62: command not found: complete
  /user/path/google-cloud-sdk/completion.zsh.inc:63: command not found: complete
  </code></pre>
  <p>I am not very versed into bash I think my installation might have been way to complex also (oh-my-zsh, prezto, powerlevel10k).
  I just would like to know how to weed out the error and fix this.</p>
  <p>my zshrc looks as follow</p>
  <pre><code>#
  # Executes commands at the start of an interactive session.
  #
  # Authors:
  #   Sorin Ionescu &lt;sorin.ionescu@gmail.com&gt;
  #
  [[ -s &quot;$HOME/.rvm/scripts/rvm&quot; ]] &amp;&amp; source &quot;$HOME/.rvm/scripts/rvm&quot; 
  # Initialise zulu plugin manager
  source &quot;${ZULU_DIR:-&quot;${ZDOTDIR:-$HOME}/.zulu&quot;}/core/zulu&quot;
  zulu init
  
  # Source Prezto.
  if [[ -s &quot;${ZDOTDIR:-$HOME}/.zprezto/init.zsh&quot; ]]; then
    source &quot;${ZDOTDIR:-$HOME}/.zprezto/init.zsh&quot;
  fi
  
  # Customize to your needs...
  autoload -Uz promptinit
  promptinit
  # Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
  # Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
  
  # Add RVM to PATH for scripting. Make sure this is the last PATH variable change.
  # export PATH=&quot;$PATH:$HOME/.rvm/rubies/ruby-2.4.1/bin/&quot;
  
  # loading ZPLUG
  export ZPLUG_HOME=/usr/local/opt/zplug
  source $ZPLUG_HOME/init.zsh
  
  export NVM_DIR=&quot;$HOME/.nvm&quot;
  [ -s &quot;$NVM_DIR/nvm.sh&quot; ] &amp;&amp; \. &quot;$NVM_DIR/nvm.sh&quot;  # This loads nvm
  [ -s &quot;$NVM_DIR/bash_completion&quot; ] &amp;&amp; \. &quot;$NVM_DIR/bash_completion&quot;  # This loads nvm bash_completion
  
  export PATH=&quot;$HOME/.yarn/bin:$HOME/.config/yarn/global/node_modules/.bin:/user/path/Library/Python/3.7/bin:$PATH&quot;
  export GOOGLE_PROJECT=&quot;$(gcloud config get-value project)&quot;
  export GOOGLE_APPLICATION_CREDENTIALS=&quot;/user/path/PROJECTS/personal/k8s/gcp-k8s-credentials.json&quot;
  
  # The next line updates PATH for the Google Cloud SDK.
  if [ -f '/user/path/google-cloud-sdk/path.zsh.inc' ]; then . '/user/path/google-cloud-sdk/path.zsh.inc'; fi
  
  # The next line enables shell command completion for gcloud.
  if [ -f '/user/path/google-cloud-sdk/completion.zsh.inc' ]; then . '/user/path/google-cloud-sdk/completion.zsh.inc'; fi
  
  # iziwork key
  export GITHUB_AUTH_TOKEN=xxx
  </code></pre>
  <p><strong>EDIT</strong></p>
  <p>Bash Version : <code>echo $BASH_VERSION</code> gives a blank line.</p>
  <p>Zsh Version : 5.7.1</p>