1
0

zlogin 1.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. # setup editors/viewers
  2. export EDITOR='nvim'
  3. export VISUAL='nvim'
  4. export PAGER='less'
  5. # let zsh find the history
  6. export HISTFILE=$HOME/.zhistory
  7. export HISTSIZE=20000
  8. if [[ -z "$LANG" ]]; then
  9. export LANG='en_US.UTF-8'
  10. fi
  11. # Ensure path arrays do not contain duplicates.
  12. typeset -gU cdpath fpath mailpath path
  13. # Set the list of directories that Zsh searches for programs.
  14. path=(
  15. /usr/local/{bin,sbin}
  16. $HOME/go/bin
  17. $path
  18. )
  19. # Set the default Less options.
  20. # Mouse-wheel scrolling has been disabled by -X (disable screen clearing).
  21. # Remove -X and -F (exit if the content fits on one screen) to enable it.
  22. export LESS='-g -i -M -R -S -w -z-4'
  23. # Set the Less input preprocessor.
  24. # Try both `lesspipe` and `lesspipe.sh` as either might exist on a system.
  25. if (( $#commands[(i)lesspipe(|.sh)] )); then
  26. export LESSOPEN="| /usr/bin/env $commands[(i)lesspipe(|.sh)] %s 2>&-"
  27. fi
  28. #
  29. # Temporary Files
  30. #
  31. if [[ ! -d "$TMPDIR" ]]; then
  32. export TMPDIR="/tmp/$LOGNAME"
  33. mkdir -p -m 700 "$TMPDIR"
  34. fi
  35. TMPPREFIX="${TMPDIR%/}/zsh"