0
0

.zshenv 2.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. ################################################################################
  2. # $PATH and similar
  3. ################################################################################
  4. export GOPATH="$HOME/.go"
  5. PATH="/opt/homebrew/bin:${PATH}"
  6. PATH="/opt/homebrew/sbin:${PATH}"
  7. PATH="/opt/homebrew/opt/ruby/bin:${PATH}"
  8. PATH="${HOME}/.scripts:${PATH}"
  9. PATH="${PATH}:/usr/local/bin"
  10. PATH="${GOPATH}/bin:${PATH}"
  11. PATH="${HOME}/.gem/bin:${PATH}"
  12. PATH="${HOME}/.cargo/bin:${PATH}"
  13. PATH="${HOME}/.poetry/bin:${PATH}"
  14. PATH="${HOME}/.rvm/bin:${PATH}"
  15. export PATH
  16. ################################################################################
  17. # Color palette and dark mode
  18. ################################################################################
  19. source $XDG_CONFIG_HOME/jonathandarker/palette.sh
  20. export LIGHTMODE_TOGGLE_FLAG_FILE="$XDG_RUNTIME_DIR/lightmode.toggled.flag"
  21. if [ -f $LIGHTMODE_TOGGLE_FLAG_FILE ]; then
  22. export JONATHANDARKER_COLOR_BG="$JONATHANDARKER_COLOR_15"
  23. export JONATHANDARKER_COLOR_BA="$JONATHANDARKER_COLOR_07"
  24. export JONATHANDARKER_COLOR_FG="$JONATHANDARKER_COLOR_00"
  25. export JONATHANDARKER_COLOR_FA="$JONATHANDARKER_COLOR_08"
  26. fi
  27. ################################################################################
  28. # Aliases
  29. ################################################################################
  30. alias n="nvim"
  31. alias lg="lazygit"
  32. alias ld="lazydocker"
  33. # git
  34. alias g="git"
  35. alias gs="git s"
  36. alias gl="git l"
  37. # ls
  38. alias ls="lsd -a"
  39. alias la="lsd -la"
  40. # clear
  41. alias c="clear && NEW_LINE_BEFORE_PROMPT=0"
  42. alias clear="clear && NEW_LINE_BEFORE_PROMPT=0"
  43. #python
  44. alias python="python3"
  45. alias py="python3"
  46. ################################################################################
  47. # nvm
  48. # Lazy-loaded, using logic from https://github.com/undg/zsh-nvm-lazy-load
  49. ################################################################################
  50. export NVM_DIR="$HOME/.nvm"
  51. load-nvm() {
  52. [ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh"
  53. [ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion"
  54. }
  55. nvm() { unset -f nvm; load-nvm; nvm "$@" }
  56. node() { unset -f node; load-nvm; node "$@"; }
  57. npm() { unset -f npm; load-nvm; npm "$@"; }
  58. pnpm() { unset -f pnpm; load-nvm; pnpm "$@"; }
  59. yarn() { unset -f yarn; load-nvm; yarn "$@"; }