summaryrefslogtreecommitdiff
path: root/.profile
diff options
context:
space:
mode:
authorMehdi Sadeghi <mehdi@mehdix.org>2022-02-23 08:02:30 +0100
committerMehdi Sadeghi <mehdi@mehdix.org>2022-03-12 13:50:56 +0100
commit001d17542cdda531fa7a2ee8ab90d47e01d251dc (patch)
treed881c7b91073f98b68f3f71103ab8b6813b9eda8 /.profile
parent61a1a18ec6616491a5472b6f94226c8126cf764a (diff)
Replace hostname with proc
Diffstat (limited to '.profile')
-rw-r--r--.profile5
1 files changed, 3 insertions, 2 deletions
diff --git a/.profile b/.profile
index cb54b12..ae6ffb5 100644
--- a/.profile
+++ b/.profile
@@ -14,7 +14,8 @@ export CXXFLAGS="${CFLAGS}"
export _JAVA_AWT_WM_NONREPARENTING=1
export GDK_BACKEND=wayland
-[ -e .config/$(hostname).profile ] && . .config/$(hostname).profile
-[ $0 != sh ] && [ -n $BASH_VERSION ] && shopt login_shell 2>&1 > /dev/null && [ -f ~/.bashrc ] && . ~/.bashrc
+HOSTNAME=$(cat /proc/sys/kernel/hostname)
+[ -e .config/$HOSTNAME.profile ] && . .config/$HOSTNAME.profile
+[ $0 != sh ] && [ -n "$BASH_VERSION" ] && shopt login_shell 2>&1 > /dev/null && [ -f ~/.bashrc ] && . ~/.bashrc
echo .profile end