summaryrefslogtreecommitdiff
path: root/.profile
diff options
context:
space:
mode:
authorMehdi Sadeghi <mehdi@mehdix.org>2021-08-29 19:28:47 +0200
committerMehdi Sadeghi <mehdi@mehdix.org>2021-08-29 19:28:47 +0200
commiteac660293c025232b7e45a392bbdf5b19af72331 (patch)
tree51a87bc29f7ac1964e82a4a0a398a3a55f453390 /.profile
parent887d5cdbc1b77578026845d6996a372b2ed991ee (diff)
Reorganize bash startup files and minor fixes.
- Move PATH exports to .env - Move aliases to .env - Avoid loading .env twice - Load .bashrc only on login shell and bash only
Diffstat (limited to '.profile')
-rw-r--r--.profile9
1 files changed, 2 insertions, 7 deletions
diff --git a/.profile b/.profile
index a63a4b3..1fa0655 100644
--- a/.profile
+++ b/.profile
@@ -1,3 +1,4 @@
+# .profile
export ENV=~/.env
export LANG=en_US.UTF-8
export LC_TIME=de_DE.UTF-8
@@ -5,12 +6,6 @@ export EDITOR=vim
export TERM=xterm
export HISTSIZE=65535
-export PATH=$HOME/.local/bin:$PATH
-export PATH=$HOME/.local/bin/`hostname`:$PATH
-export PATH=$HOME/.local/bin/`uname -m`:$PATH
-export PATH=$HOME/.cargo/bin:$PATH
-export GOPATH="$HOME/.local/share/go"
-export PATH=$GOPATH/bin:$PATH
export MAKEFLAGS=-j`lscpu | grep '^CPU(s):' | awk -F' ' '{ print $2 }'`
export CFLAGS="-O2 -pipe -march=native"
export CXXFLAGS="${CFLAGS}"
@@ -19,4 +14,4 @@ export _JAVA_AWT_WM_NONREPARENTING=1
export GDK_BACKEND=wayland
[ -e .config/$(hostname).profile ] && . .config/$(hostname).profile
-[ $0 = bash ] || [ $0 = '-bash' ] && [ -f ~/.bashrc ] && . ~/.bashrc
+[ -n $BASH_VERSION ] && shopt login_shell 2>&1 > /dev/null && [ -f ~/.bashrc ] && . ~/.bashrc