aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xxsessionrc.dot.link15
1 files changed, 8 insertions, 7 deletions
diff --git a/xsessionrc.dot.link b/xsessionrc.dot.link
index df2ec03..9a3c53c 100755
--- a/xsessionrc.dot.link
+++ b/xsessionrc.dot.link
@@ -13,7 +13,8 @@ PROGRAMS="xconky blueman-applet xnm-tray pasystray"
OSVERSION="`cut -d . -f 1 /etc/debian_version`"
# Hostname
-HOSTNAME="`cat /etc/hostname`"
+HOSTNAME="`cat /etc/hostname | cut -d . -f 1`"
+FQDN="`cat /etc/hostname`"
# Output
# Example: OUTPUT="VGA-1"
@@ -110,21 +111,21 @@ if [ -f "$HOME/.Xmodmap" ]; then
fi
# Apply custom keyboard configuration
-if [ -f "$HOME/.Xmodmaps/$HOSTNAME" ]; then
- xmodmap $HOME/.Xmodmaps/$HOSTNAME
+if [ -f "$HOME/.Xmodmaps/$FQDN" ]; then
+ xmodmap $HOME/.Xmodmaps/$FQDN
# Why xmodmap has to run twice to some changes take place?
# https://faq.i3wm.org/question/558/xmodmap-loading/
# https://bugs.launchpad.net/ubuntu/+source/gdm/+bug/700309
- xmodmap $HOME/.Xmodmaps/$HOSTNAME
+ xmodmap $HOME/.Xmodmaps/$FQDN
fi
# Fix mumble configuration, which varies depending on machine audio
-if [ -f "$HOME/.config/Mumble/Mumble-$HOSTNAME.conf" ]; then
+if [ -f "$HOME/.config/Mumble/Mumble-$FQDN.conf" ]; then
(
cd $HOME/.config/Mumble
- mv Mumble.conf Mumble-$HOSTNAME.conf.backup
- ln -s Mumble-$HOSTNAME.conf Mumble.conf
+ mv Mumble.conf Mumble-$FQDN.conf.backup
+ ln -s Mumble-$FQDN.conf Mumble.conf
)
fi