Move purely environment related zsh initialization to .zshenv
authorSergey Matveev <stargrave@stargrave.org>
Mon, 2 Sep 2019 12:04:29 +0000 (15:04 +0300)
committerSergey Matveev <stargrave@stargrave.org>
Mon, 2 Sep 2019 13:19:22 +0000 (16:19 +0300)
zsh/.zprofile
zsh/.zshenv [new file with mode: 0644]
zsh/.zshrc

index 709802134c08156244da38fe947040f0c1c426bf..aa321e3790840851958bfa0764be1628ce89b411 100644 (file)
@@ -1,71 +1,4 @@
-# vim: foldmethod=marker:foldlevel=0
-
-# History {{{
-HISTFILE=~/secure/.history
-HISTSIZE=10240
-SAVEHIST=10240
-# }}}
-
-# Terminal {{{
-export COLORFGBG="default;default;0"
-export COLORTERM="xterm-256color"
-[ "$TERM" = "screen-256color" ] || TERM=xterm-256color
-export TERM
-# }}}
-
-# Basic envs {{{
-export SHELL=/bin/zsh
-export EDITOR=vim
-export PATH=$PATH:$HOME/bin:/sbin:/usr/sbin
-export TZ='Europe/Moscow'
-export IFCONFIG_FORMAT=inet:cidr,inet6:cidr
-export SSH_AUTH_SOCK=$HOME/.ssh/agent
-# }}}
-
-# Less options {{{
-export PAGER=less
-export LESSHISTFILE=-
-export LESS=RXi
-# }}}
-
-# ls options {{{
-export CLICOLOR=1
-export LSCOLORS="BxGxcxdxCxegDxabagacad"
-# }}}
-
-# Lynx options {{{
-export WWW_HOME=file:///home/stargrave/.lynx_bookmarks.html
-export SSL_CERT_FILE=/usr/local/openssl/cert.pem
-export LYNX_CFG=~/.lynx.cfg
-# }}}
-
-# sdcv options {{{
-export STARDICT_DATA_DIR=$HOME
-export SDCV_HISTSIZE=0
-# }}}
-
-# IRC options {{{
-export IRCNAME="Sergey Matveev"
-export IRCNICK="stargrave"
-# }}}
-
-# Python options {{{
-export PIP_RESPECT_VIRTUALENV=true
-export PIP_VIRTUALENV_BASE=~/.virtualenvs
-export PYTHONDONTWRITEBYTECODE=1
-# }}}
-
-export MAILDIR=$HOME/mail
-
-# XDG related junk {{{
-mkdir -p /tmp/stargrave-xdg
-export XDG_CACHE_HOME=/tmp/stargrave-xdg
-export XDG_CONFIG_DIR=/tmp/stargrave-xdg
-export XDG_DATA_HOME=/tmp/stargrave-xdg
-export XDG_RUNTIME_DIR=/tmp/stargrave-xdg
-# }}}
-
-export GOCACHE=/tmp/go-cache
 umask 077
-
+mkdir -p /tmp/stargrave-xdg
 env | grep -q XAUTH || calendar
+~/bin/cleanup.sh
diff --git a/zsh/.zshenv b/zsh/.zshenv
new file mode 100644 (file)
index 0000000..90dc9ee
--- /dev/null
@@ -0,0 +1,88 @@
+# vim: foldmethod=marker:foldlevel=0
+
+# History {{{
+HISTFILE=~/secure/.history
+HISTSIZE=10240
+SAVEHIST=10240
+# }}}
+
+# Terminal {{{
+export COLORFGBG="default;default;0"
+export COLORTERM="xterm-256color"
+[ "$TERM" = "screen-256color" ] || TERM=xterm-256color
+export TERM
+# }}}
+
+# Less options {{{
+export PAGER=less
+export LESSHISTFILE=-
+export LESS=RXi
+# }}}
+
+# ls options {{{
+export CLICOLOR=1
+export LSCOLORS="BxGxcxdxCxegDxabagacad"
+# }}}
+
+# Lynx options {{{
+export WWW_HOME=file:///home/stargrave/.lynx_bookmarks.html
+export SSL_CERT_FILE=/usr/local/openssl/cert.pem
+export LYNX_CFG=~/.lynx.cfg
+# }}}
+
+# sdcv options {{{
+export STARDICT_DATA_DIR=$HOME
+export SDCV_HISTSIZE=0
+# }}}
+
+# IRC options {{{
+export IRCNAME="Sergey Matveev"
+export IRCNICK="stargrave"
+# }}}
+
+# Python options {{{
+export PIP_RESPECT_VIRTUALENV=true
+export PIP_VIRTUALENV_BASE=~/.virtualenvs
+export PYTHONDONTWRITEBYTECODE=1
+# }}}
+
+# XDG related junk {{{
+export XDG_CACHE_HOME=/tmp/stargrave-xdg
+export XDG_CONFIG_DIR=/tmp/stargrave-xdg
+export XDG_DATA_HOME=/tmp/stargrave-xdg
+export XDG_RUNTIME_DIR=/tmp/stargrave-xdg
+# }}}
+
+# Paths {{{
+export CFLAGS="-I/usr/local/include" LDFLAGS="-L/usr/local/lib"
+
+export PATH=$PATH:$HOME/bin:/sbin:/usr/sbin
+
+export MANPATH=/usr/share/man
+export MANPATH=/usr/local/man:$MANPATH
+export MANPATH=/usr/local/share/man:$MANPATH
+export MANPATH=/usr/share/openssl/man:$MANPATH
+export MANPATH=/usr/local/lib/perl5/site_perl/man:$MANPATH
+export MANPATH=/usr/local/lib/perl5/5.26/perl/man:$MANPATH
+
+export PATH=$HOME/git/bin:$PATH
+export MANPATH=$HOME/git/share/man:$MANPATH
+
+# export PATH=$HOME/postgresql/bin:$PATH
+# export MANPATH=$HOME/postgresql/share/man:$MANPATH
+# [ -e ~/postgresql/lib/libpq.so.5 ] && export LD_PRELOAD=$HOME/postgresql/lib/libpq.so.5
+
+# export PATH=$HOME/texlive/2017/bin/amd64-freebsd:$PATH
+# export INFOPATH=/usr/local/share/info:$HOME/texlive/2017/texmf-dist/doc/info:$INFOPATH
+# export MANPATH=$HOME/texlive/2017/texmf-dist/doc/man:$MANPATH
+# }}}
+
+# Various {{{
+export SHELL=/bin/zsh
+export EDITOR=vim
+export TZ='Europe/Moscow'
+export IFCONFIG_FORMAT=inet:cidr,inet6:cidr
+export SSH_AUTH_SOCK=$HOME/.ssh/agent
+export GOCACHE=/tmp/go-cache
+export MAILDIR=$HOME/mail
+# }}}
index afd966782203ba34275bc0e8ea3d8db21af48fc6..a2e3e64507f2134d1c3df46dd390bcbdb5a9c944 100644 (file)
@@ -153,31 +153,6 @@ autoload -U zcalc
 alias zc="zcalc"
 # }}}
 
-# Paths {{{
-export CFLAGS="-I/usr/local/include" LDFLAGS="-L/usr/local/lib"
-
-export MANPATH=/usr/share/man
-export MANPATH=/usr/local/man:$MANPATH
-export MANPATH=/usr/local/share/man:$MANPATH
-export MANPATH=/usr/share/openssl/man:$MANPATH
-export MANPATH=/usr/local/lib/perl5/site_perl/man:$MANPATH
-export MANPATH=/usr/local/lib/perl5/5.26/perl/man:$MANPATH
-
-export PATH=$HOME/git/bin:$PATH
-export MANPATH=$HOME/git/share/man:$MANPATH
-
-# export PATH=$HOME/postgresql/bin:$PATH
-# export MANPATH=$HOME/postgresql/share/man:$MANPATH
-# [ -e ~/postgresql/lib/libpq.so.5 ] && export LD_PRELOAD=$HOME/postgresql/lib/libpq.so.5
-
-# export PATH=$HOME/texlive/2017/bin/amd64-freebsd:$PATH
-# export INFOPATH=/usr/local/share/info:$HOME/texlive/2017/texmf-dist/doc/info:$INFOPATH
-# export MANPATH=$HOME/texlive/2017/texmf-dist/doc/man:$MANPATH
-
-export PATH=$HOME/stow/bin:$PATH
-export MANPATH=$HOME/stow/share/man:$MANPATH
-export INFOPATH=$HOME/stow/share/info:$INFOPATH
-# }}}
 
 # Completion {{{
 zstyle ":completion:*:functions" ignored-patterns "_*"
@@ -210,4 +185,3 @@ ZSH_HIGHLIGHT_STYLES[assign]="fg=cyan"
 ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=6"
 # }}}
 
-~/bin/cleanup.sh