X-Git-Url: http://gitweb.pimeys.fr/?a=blobdiff_plain;f=.zsh%2Frc%2Fbase%2F20_env;fp=.zsh%2Frc%2Fbase%2F20_env;h=6a630d713a90bbd910d2174c3fe7ad27d7bb00a9;hb=3d71eab53c5b63556363ece880859b0af7f162da;hp=0000000000000000000000000000000000000000;hpb=1f8b08895681d46802368eec0764ca70d08898ca;p=config-20-100.git diff --git a/.zsh/rc/base/20_env b/.zsh/rc/base/20_env new file mode 100644 index 0000000..6a630d7 --- /dev/null +++ b/.zsh/rc/base/20_env @@ -0,0 +1,83 @@ +#x compatibility +xsource "/etc/default/locale" + +for var in LANG LC_ALL LC_MESSAGES ; do + [[ -n ${(P)var} ]] && export $var +done + +xsource "/etc/sysconfig/keyboard" + +#Sets timezone +TZ=$(xcat /etc/timezone) + +# color setup for ls: +check_com -c dircolors && eval $(dircolors -b) + +# Pager +export PAGER=less + +# While in doubt. +export SHELL='/bin/zsh' + +# Colors in less... +export LESS_TERMCAP_mb=$'\E[01;31m' # begin blinking +export LESS_TERMCAP_md=$'\E[01;38;5;74m' # begin bold +export LESS_TERMCAP_me=$'\E[0m' # end mode +export LESS_TERMCAP_se=$'\E[0m' # end standout-mode +export LESS_TERMCAP_so=$'\E[38;5;246m' # begin standout-mode - info box +export LESS_TERMCAP_ue=$'\E[0m' # end underline +export LESS_TERMCAP_us=$'\E[04;38;5;146m' # begin underline +export LESS="-SR" + +# does not need export +MAILCHECK=30 # mailchecks +REPORTTIME=5 # report about cpu-/system-/user-time of command if running longer than 5 seconds +watch=(notme root) # watch for everyone but me and root + +# automatically remove duplicates from these arrays +typeset -U path cdpath fpath manpath +# adding personnal completion files in fpath +fpath=(~/.zsh/completion $fpath) + +if [ $TERM = "rxvt-unicode-256color" ]; then + export TERM=rxvt-unicode +fi + +#+---------------------------------------+ +#| HISTORY | +#+---------------------------------------+ +h=$(hostname --fqdn) + +#v# +HISTFILE=$ZSHDIR/history-$h +HISTSIZE=100000 +SAVEHIST=100000 +export HISTFILE HISTSIZE SAVEHIST + +############ MISC ################## +# set terminal property (used e.g. by msgid-chooser) +export COLORTERM="yes" + +# set default browser +if [[ -z "$BROWSER" ]] ; then + if [[ -n "$DISPLAY" ]] ; then + #v# If X11 is running + check_com -c firefox && export BROWSER=firefox + else + #v# If no X11 is running + check_com -c w3m && export BROWSER=w3m + fi +fi + +#m# v QTDIR \kbd{/usr/share/qt[34]}\quad [for non-root only] +[[ -d /usr/share/qt3 ]] && export QTDIR=/usr/share/qt3 +[[ -d /usr/share/qt4 ]] && export QTDIR=/usr/share/qt4 + +# support running 'jikes *.java && jamvm HelloWorld' OOTB: +#v# [for non-root only] +[[ -f /usr/share/classpath/glibj.zip ]] && export JIKESPATH=/usr/share/classpath/glibj.zip +# }}} + +# umask personnal config file +# used to set specific umask +UMASKFILE=~/.umask