From 80adf828d041fd30c2bfb584b2a1b12c53ad1a5a Mon Sep 17 00:00:00 2001 From: Jonas Gunz Date: Fri, 2 Dec 2022 00:29:52 +0100 Subject: bash --- bash/10-env.profile | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 bash/10-env.profile (limited to 'bash/10-env.profile') diff --git a/bash/10-env.profile b/bash/10-env.profile new file mode 100644 index 0000000..d7e09b9 --- /dev/null +++ b/bash/10-env.profile @@ -0,0 +1,30 @@ +# vi:filetype=sh + +function appendpath() { + local regex="[:^]${1//'/'/'\/'}[:$]" + if [[ ! ${PATH} =~ $regex ]]; then + PATH=$PATH:$1 + fi +} + +appendpath "$HOME/bin" +appendpath "$DOTFILEBASE/scripts" +appendpath "$HOME/.local/bin" +appendpath "$HOME/go/bin" +appendpath "$HOME/.cabal/bin" +appendpath "$HOME/.ghcup/bin" + +export PATH +unset appendpath + +if which nvim > /dev/null 2>&1 && [ ! "$FORCE_VANILLA_VIM" = "yes" ] ; then + export EDITOR=nvim +else + export EDITOR=vim +fi + +#Java Gradle hopme PATH +export GRADLE_USER_HOME=~/.gradle + +export HISTTIMEFORMAT="%y-%m-%d %T " +export HISTSIZE=1000 -- cgit v1.2.3