Renamed .env => .bash.env to free .env name for user customization (famous dotenv file).
--- a/.bashrc Tue Jun 01 11:55:32 2021 +0300
+++ b/.bashrc Tue Jun 01 17:34:17 2021 +0300
@@ -2,11 +2,8 @@
# set -x
# set -u
-# XXX
-# [[ -f /etc/bashrc ]] && . /etc/bashrc
-
-if [[ -f ~/.env ]]; then
- . ~/.env
+if [[ -f ~/.env.bash ]]; then
+ . ~/.env.bash
fi
shopt -s checkwinsize
@@ -227,11 +224,11 @@
fi
################################################################
-# Load custom settings (user editable).
+# Load user defined settings.
# Placed to the end to allow override skel settings.
-if [[ -f ~/.env.local ]]; then
- . ~/.env.local
+if [[ -f ~/.env ]]; then
+ . ~/.env
fi
################################################################
--- a/.env Tue Jun 01 11:55:32 2021 +0300
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,90 +0,0 @@
-# Bash and Zsh common env var settings. -*- sh -*-
-
-# set -x
-# set -u
-
-export DEBFULLNAME='Oleksandr Gavenko'
-export DEBEMAIL='gavenkoa@gmail.com'
-
-export EDITOR=vim
-
-# XXX vim and gnome-terminal have support for 256 colours in fedora 8 at least
-# Note debian/ubuntu users should install the ncurses-term package to support this
-# export TERM=xterm-256color
-
-if [[ $OSTYPE = cygwin ]]; then
- # Avoid permission problem in Cygwin.
- umask 0000
-fi
-
-export TIME_STYLE=long-iso
-
-# Easy cd to often used dirs.
-export CDPATH=.:$HOME:$HOME/devel:$HOME/my
-
-if [[ ! :$PATH: =~ :$HOME/usr/xbin: ]]; then
- # To override /bin and /usr/bin.
- export PATH=$HOME/usr/xbin:$PATH
-fi
-if [[ ! :$PATH: =~ :$HOME/usr/bin: ]]; then
- export PATH=$PATH:$HOME/usr/bin
-fi
-if [[ ! :$PATH: =~ :/usr/sbin: ]]; then
- export PATH=/usr/sbin:$PATH
-fi
-if [[ ! :$PATH: =~ :/sbin: ]]; then
- export PATH=/sbin:$PATH
-fi
-if [[ ! :$PATH: =~ :$HOME/.local/bin: ]]; then
- export PATH=$PATH:$HOME/.local/bin
-fi
-if [[ $OSTYPE = solaris* && ! :$PATH: =~ :/opt/csw/bin: ]]; then
- export PATH=$PATH:/opt/csw/bin
-fi
-
-
-[[ -z $LD_LIBRARY_PATH ]] && LD_LIBRARY_PATH=$HOME/usr/lib
-if [[ ! :$LD_LIBRARY_PATH: =~ :$HOME/usr/lib: ]]; then
- export LD_LIBRARY_PATH="$LD_LIBRARY_PATH":$HOME/usr/lib
-fi
-
-case $OSTYPE in
- netbsd*) ;; # Do nothing, because NetBSD uses non-GNU man.
- *)
- if [[ -z $MANPATH ]]; then
- export MANPATH=$HOME/usr/share/man:
- elif [[ ! $MANPATH =~ $HOME/usr/share/man: ]]; then
- export MANPATH=$MANPATH:$HOME/usr/share/man:
- fi
- ;;
-esac
-
-if [[ -z $INFOPATH ]]; then
- export INFOPATH=$HOME/usr/share/info:
-elif [[ ! $INFOPATH =~ $HOME/usr/share/info: ]]; then
- export INFOPATH=$INFOPATH:$HOME/usr/share/info:
-fi
-
-export PYTHONSTARTUP=$HOME/.pystartup
-
-xopt='-Dorg.gradle.daemon=true'
-if [[ $GRADLE_OPTS != *${xopt}* ]]; then
- GRADLE_OPTS="$GRADLE_OPTS ${xopt}"
-fi
-# export GRADLE_OPTS="$GRADLE_OPTS -Dorg.gradle.console=plain"
-# if [[ $OSTYPE = cygwin ]]; then
-# xopt='-Dorg.gradle.console=verbose'
-# if [[ $GRADLE_OPTS != *${xopt}* ]]; then
-# GRADLE_OPTS="$GRADLE_OPTS ${xopt}"
-# fi
-# fi
-# GRADLE_OPTS="$GRADLE_OPTS -Djava.io.tmpdir=c:/tmp"
-export GRADLE_OPTS
-
-if [[ ! :$PATH: =~ :$HOME/.npm-packages/bin: ]]; then
- export PATH=$PATH:$HOME/.npm-packages/bin
-fi
-
-export RLWRAP_HOME=$HOME/.rlwrap
-
-unset xopt
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/.env.bash Tue Jun 01 17:34:17 2021 +0300
@@ -0,0 +1,90 @@
+# Bash and Zsh common env var settings. -*- sh -*-
+
+# set -x
+# set -u
+
+export DEBFULLNAME='Oleksandr Gavenko'
+export DEBEMAIL='gavenkoa@gmail.com'
+
+export EDITOR=vim
+
+# XXX vim and gnome-terminal have support for 256 colours in fedora 8 at least
+# Note debian/ubuntu users should install the ncurses-term package to support this
+# export TERM=xterm-256color
+
+if [[ $OSTYPE = cygwin ]]; then
+ # Avoid permission problem in Cygwin.
+ umask 0000
+fi
+
+export TIME_STYLE=long-iso
+
+# Easy cd to often used dirs.
+export CDPATH=.:$HOME:$HOME/devel:$HOME/my
+
+if [[ ! :$PATH: =~ :$HOME/usr/xbin: ]]; then
+ # To override /bin and /usr/bin.
+ export PATH=$HOME/usr/xbin:$PATH
+fi
+if [[ ! :$PATH: =~ :$HOME/usr/bin: ]]; then
+ export PATH=$PATH:$HOME/usr/bin
+fi
+if [[ ! :$PATH: =~ :/usr/sbin: ]]; then
+ export PATH=/usr/sbin:$PATH
+fi
+if [[ ! :$PATH: =~ :/sbin: ]]; then
+ export PATH=/sbin:$PATH
+fi
+if [[ ! :$PATH: =~ :$HOME/.local/bin: ]]; then
+ export PATH=$PATH:$HOME/.local/bin
+fi
+if [[ $OSTYPE = solaris* && ! :$PATH: =~ :/opt/csw/bin: ]]; then
+ export PATH=$PATH:/opt/csw/bin
+fi
+
+
+[[ -z $LD_LIBRARY_PATH ]] && LD_LIBRARY_PATH=$HOME/usr/lib
+if [[ ! :$LD_LIBRARY_PATH: =~ :$HOME/usr/lib: ]]; then
+ export LD_LIBRARY_PATH="$LD_LIBRARY_PATH":$HOME/usr/lib
+fi
+
+case $OSTYPE in
+ netbsd*) ;; # Do nothing, because NetBSD uses non-GNU man.
+ *)
+ if [[ -z $MANPATH ]]; then
+ export MANPATH=$HOME/usr/share/man:
+ elif [[ ! $MANPATH =~ $HOME/usr/share/man: ]]; then
+ export MANPATH=$MANPATH:$HOME/usr/share/man:
+ fi
+ ;;
+esac
+
+if [[ -z $INFOPATH ]]; then
+ export INFOPATH=$HOME/usr/share/info:
+elif [[ ! $INFOPATH =~ $HOME/usr/share/info: ]]; then
+ export INFOPATH=$INFOPATH:$HOME/usr/share/info:
+fi
+
+export PYTHONSTARTUP=$HOME/.pystartup
+
+xopt='-Dorg.gradle.daemon=true'
+if [[ $GRADLE_OPTS != *${xopt}* ]]; then
+ GRADLE_OPTS="$GRADLE_OPTS ${xopt}"
+fi
+# export GRADLE_OPTS="$GRADLE_OPTS -Dorg.gradle.console=plain"
+# if [[ $OSTYPE = cygwin ]]; then
+# xopt='-Dorg.gradle.console=verbose'
+# if [[ $GRADLE_OPTS != *${xopt}* ]]; then
+# GRADLE_OPTS="$GRADLE_OPTS ${xopt}"
+# fi
+# fi
+# GRADLE_OPTS="$GRADLE_OPTS -Djava.io.tmpdir=c:/tmp"
+export GRADLE_OPTS
+
+if [[ ! :$PATH: =~ :$HOME/.npm-packages/bin: ]]; then
+ export PATH=$PATH:$HOME/.npm-packages/bin
+fi
+
+export RLWRAP_HOME=$HOME/.rlwrap
+
+unset xopt
--- a/.zshrc Tue Jun 01 11:55:32 2021 +0300
+++ b/.zshrc Tue Jun 01 17:34:17 2021 +0300
@@ -3,8 +3,8 @@
. /etc/zshrc
fi
-if [[ -f ~/.env ]]; then
- . ~/.env
+if [[ -f ~/.bash.env ]]; then
+ . ~/.bash.env
fi
PS1=$'%?|%n@%m %~\nzsh# '
@@ -77,3 +77,11 @@
# Renaming with globbing
# autoload zmv
+
+################################################################
+# Load user defined settings.
+# Placed to the end to allow override skel settings.
+
+if [[ -f ~/.env ]]; then
+ . ~/.env
+fi
--- a/Makefile Tue Jun 01 11:55:32 2021 +0300
+++ b/Makefile Tue Jun 01 17:34:17 2021 +0300
@@ -66,7 +66,8 @@
.inputrc .Xdefaults .xinitrc .xserverrc \
.screenrc .tmux.conf \
.dircolors .colordiffrc \
- .env .bashrc .bash_completion .bash_completion.d .zshrc .vimrc .ssh \
+ .bashrc .env.bash .bash_completion .bash_completion.d .zshrc \
+ .vimrc .ssh \
.pylintrc .pystartup .tclshrc .npmrc .guile \
.gradle/init.d/springColorLogging.gradle \
.sqshrc .psqlrc \
@@ -95,7 +96,7 @@
dist-mini: $(TARBALL_MINI)
define TARBALL_MINI_DEPS
-.bashrc .env .bash_completion \
+.bashrc .env.bash .bash_completion \
.inputrc .dircolors \
.gitconfig .gitignore .hgrc .hgignore .hgstyle
endef