.zshrc 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. # benchmark startup:
  2. # zmodload zsh/zprof
  3. # load all files from .shell/zshrc.d directory
  4. if [ -d $HOME/.zshrc.d ]; then
  5. for file in $HOME/.zshrc.d/*.zsh; do
  6. source $file
  7. done
  8. fi
  9. # load all files from .shell/rc.d directory
  10. if [ -d $HOME/.rc.d ]; then
  11. for file in $HOME/.rc.d/*.sh; do
  12. source $file
  13. done
  14. fi
  15. if [[ -n $SSH_CONNECTION ]]; then
  16. export EDITOR='vim'
  17. else
  18. export EDITOR='code --wait'
  19. fi
  20. # The next line updates PATH for the Google Cloud SDK.
  21. if [ -f '/Users/tom/google-cloud-sdk/path.zsh.inc' ]; then . '/Users/tom/google-cloud-sdk/path.zsh.inc'; fi
  22. # The next line enables shell command completion for gcloud.
  23. if [ -f '/Users/tom/google-cloud-sdk/completion.zsh.inc' ]; then . '/Users/tom/google-cloud-sdk/completion.zsh.inc'; fi
  24. if [ -f '/opt/homebrew/bin/brew' ]; then eval "$(/opt/homebrew/bin/brew shellenv)"; fi
  25. # bun completions
  26. [ -s "/Users/tom/.bun/_bun" ] && source "/Users/tom/.bun/_bun"
  27. # bun
  28. export BUN_INSTALL="$HOME/.bun"
  29. export PATH="$BUN_INSTALL/bin:$PATH"
  30. # zoxide
  31. if command -v zoxide >/dev/null 2>&1; then eval "$(zoxide init zsh)"; fi