You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
64 lines
2.0 KiB
64 lines
2.0 KiB
# Sourced in login shells before .zshrc
|
|
# Commands that should be exectued only in login shells
|
|
# Do not set environment variables
|
|
# Do not define alias, functions, options, etc.
|
|
#
|
|
# +--------------------+-------+-------+--------+
|
|
# | | Inter | Inter | Script |
|
|
# | | Login | | |
|
|
# +====================+=======+=======+========+
|
|
# | /etc/zshenv | A | A | A |
|
|
# +--------------------+-------+-------+--------+
|
|
# | $ZDOTDIR/.zshenv | B | B | B |
|
|
# +--------------------+-------+-------+--------+
|
|
# | /etc/zprofile | C | | |
|
|
# +--------------------+-------+-------+--------+
|
|
# | $ZDOTDIR/.zprofile | D | | |
|
|
# +--------------------+-------+-------+--------+
|
|
# | /etc/zshrc | E | C | |
|
|
# +--------------------+-------+-------+--------+
|
|
# | $ZDOTDIR/.zshrc | F | D | |
|
|
# +--------------------+-------+-------+--------+
|
|
# | /etc/zlogin | G | | |
|
|
# +--------------------+-------+-------+--------+
|
|
# | $ZDOTDIR/.zlogin | H | | |
|
|
# +--------------------+-------+-------+--------+
|
|
|
|
# Browser
|
|
case `/usr/bin/uname -s` in
|
|
Darwin)
|
|
export BROWSER='open'
|
|
;;
|
|
esac
|
|
|
|
# Editors
|
|
export EDITOR='vim'
|
|
export VISUAL='vim'
|
|
export PAGER='less'
|
|
export LESSEDIT='vim'
|
|
|
|
# Language
|
|
if [[ -z "$LANG" ]]; then
|
|
export LANG='en_US.UTF-8'
|
|
fi
|
|
|
|
# Set the default Less options.
|
|
# Mouse-wheel scrolling has been disabled by -X (disable screen clearing).
|
|
# Remove -X and -F (exit if the content fits on one screen) to enable it.
|
|
export LESS='-F -g -i -M -R -S -w -X -z-4'
|
|
|
|
# Set the Less input preprocessor.
|
|
# Try both `lesspipe` and `lesspipe.sh` as either might exist on a system.
|
|
if (( $#commands[(i)lesspipe(|.sh)] )); then
|
|
export LESSOPEN="| /usr/bin/env $commands[(i)lesspipe(|.sh)] %s 2>&-"
|
|
fi
|
|
|
|
# Temporary Files
|
|
if [[ ! -d "$TMPDIR" ]]; then
|
|
export TMPDIR="/tmp/$LOGNAME"
|
|
mkdir -p -m 700 "$TMPDIR"
|
|
fi
|
|
|
|
TMPPREFIX="${TMPDIR%/}/zsh"
|
|
|