2 # Executes commands at login pre-zshrc.
5 # Sorin Ionescu <sorin.ionescu@gmail.com>
12 if [[ "$OSTYPE" == darwin* ]]; then
28 if [[ -z "$LANG" ]]; then
29 export LANG='en_US.UTF-8'
36 # Ensure path arrays do not contain duplicates.
37 typeset -gU cdpath fpath mailpath path
39 # Set the the list of directories that cd searches.
44 # Set the list of directories that Zsh searches for programs.
54 # Set the default Less options.
55 # Mouse-wheel scrolling has been disabled by -X (disable screen clearing).
56 # Remove -X and -F (exit if the content fits on one screen) to enable it.
57 export LESS='-F -g -i -M -R -S -w -X -z-4'
59 # Set the Less input preprocessor.
60 # Try both `lesspipe` and `lesspipe.sh` as either might exist on a system.
61 if (( $#commands[(i)lesspipe(|.sh)] )); then
62 export LESSOPEN="| /usr/bin/env $commands[(i)lesspipe(|.sh)] %s 2>&-"
69 if [[ ! -d "$TMPDIR" ]]; then
70 export TMPDIR="/tmp/$LOGNAME"
71 mkdir -p -m 700 "$TMPDIR"
74 TMPPREFIX="${TMPDIR%/}/zsh"