Move some settings from profile to zshenv
.zshenv is run everytime a zsh instance is started, including subshells and the like. Use this file, now, to set things like PATH and such that are used frequently. Add a setup symlink for .zshenv
This commit is contained in:
parent
7d308754fc
commit
8799338169
3 changed files with 27 additions and 16 deletions
17
profile
17
profile
|
@ -1,23 +1,11 @@
|
||||||
# .profile
|
# .profile
|
||||||
# vim: ft=zsh
|
# vim: ft=zsh
|
||||||
# Eryn Wells <eryn@3b518c.com>
|
# Eryn Wells <eryn@erynwells.me>
|
||||||
|
|
||||||
# Environment settings
|
|
||||||
PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/X11/bin
|
|
||||||
PAGER="less"
|
|
||||||
MANPAGER="less"
|
|
||||||
EDITOR="vim"
|
|
||||||
VISUAL=$EDITOR
|
|
||||||
LESSHISTFILE="-"
|
|
||||||
GREP_OPTIONS="--color=auto"
|
|
||||||
GREP_COLOR="1;32"
|
|
||||||
export PAGER MANPAGER EDITOR VISUAL LESSHISTFILE GREP_OPTIONS GREP_COLOR
|
|
||||||
|
|
||||||
# Gotta do some machine specific setup
|
# Gotta do some machine specific setup
|
||||||
arch=`uname -s`
|
arch=`uname -s`
|
||||||
case $arch in
|
case $arch in
|
||||||
Linux)
|
Linux)
|
||||||
export MAIL="/var/mail/$USER"
|
|
||||||
alias iptls='sudo iptables --line-numbers -nv -L'
|
alias iptls='sudo iptables --line-numbers -nv -L'
|
||||||
alias ip6tls='sudo ip6tables --line-numbers -nv -L'
|
alias ip6tls='sudo ip6tables --line-numbers -nv -L'
|
||||||
alias rlx="xrdb $HOME/.Xdefaults"
|
alias rlx="xrdb $HOME/.Xdefaults"
|
||||||
|
@ -26,7 +14,6 @@ case $arch in
|
||||||
Darwin)
|
Darwin)
|
||||||
alias indent='gnuindent'
|
alias indent='gnuindent'
|
||||||
alias acls='/bin/ls -le'
|
alias acls='/bin/ls -le'
|
||||||
PATH=/opt/local/bin:$PATH
|
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
@ -35,8 +22,6 @@ esac
|
||||||
export NETHACKOPTIONS="color"
|
export NETHACKOPTIONS="color"
|
||||||
|
|
||||||
[ -e $HOME/.profile-local ] && source $HOME/.profile-local
|
[ -e $HOME/.profile-local ] && source $HOME/.profile-local
|
||||||
[ -d $HOME/.local/bin ] && PATH=$HOME/.local/bin:$PATH
|
|
||||||
[ -d $HOME/bin ] && PATH=$HOME/bin:$PATH
|
|
||||||
|
|
||||||
# Start SSH agent for password-less logins
|
# Start SSH agent for password-less logins
|
||||||
if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]
|
if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]
|
||||||
|
|
1
setup.sh
1
setup.sh
|
@ -8,6 +8,7 @@ ln -s $dfdir/rc $HOME/.rc
|
||||||
ln -s $dfdir/zshrc $HOME/.zshrc
|
ln -s $dfdir/zshrc $HOME/.zshrc
|
||||||
ln -s $dfdir/zsh $HOME/.zsh
|
ln -s $dfdir/zsh $HOME/.zsh
|
||||||
ln -s $dfdir/zprofile $HOME/.zprofile
|
ln -s $dfdir/zprofile $HOME/.zprofile
|
||||||
|
ln -s $dfdir/zshenv $HOME/.zshenv
|
||||||
|
|
||||||
ln -s $dfdir/vimrc $HOME/.vimrc
|
ln -s $dfdir/vimrc $HOME/.vimrc
|
||||||
ln -s $dfdir/vim $HOME/.vim
|
ln -s $dfdir/vim $HOME/.vim
|
||||||
|
|
25
zshenv
Normal file
25
zshenv
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
# .zshenv
|
||||||
|
# vim: ft=zsh
|
||||||
|
# Eryn Wells <eryn@erynwells.me>
|
||||||
|
|
||||||
|
|
||||||
|
PATH=/usr/local/bin:/usr/bin:/bin:/usr/local/sbin:/usr/sbin:/sbin:/usr/X11/bin
|
||||||
|
[ -d /opt/local/bin ] && PATH=$PATH:/opt/local/bin
|
||||||
|
[ -d $HOME/.local/bin ] && PATH=$PATH:$HOME/.local/bin
|
||||||
|
[ -d $HOME/bin ] && PATH=$PATH:$HOME/bin
|
||||||
|
|
||||||
|
PAGER="less"
|
||||||
|
MANPAGER=$PAGER
|
||||||
|
EDITOR="vim"
|
||||||
|
VISUAL=$EDITOR
|
||||||
|
LESSHISTFILE="-"
|
||||||
|
GREP_OPTIONS="--color=auto"
|
||||||
|
GREP_COLOR="1;32"
|
||||||
|
|
||||||
|
export PATH \
|
||||||
|
PAGER MANPAGER \
|
||||||
|
EDITOR VISUAL \
|
||||||
|
LESSHISTFILE \
|
||||||
|
GREP_OPTIONS GREP_COLOR
|
||||||
|
|
||||||
|
[ `uname -s` = "Linux" ] && export MAIL="/var/mail/$USER"
|
Loading…
Add table
Add a link
Reference in a new issue