shell-things/rc/profile

40 lines
1.2 KiB
Plaintext
Raw Permalink Normal View History

# Set PATH properly
PATH=$HOME/.local/bin:$HOME/bin:$HOME/go/bin:$HOME/.local/share/flatpak/exports/bin:/var/lib/flatpak/exports/bin:/snap/bin:/usr/local/bin:/usr/local/sbin:/usr/local/games:/usr/bin:/usr/sbin:/usr/games:/bin:/sbin:/games:$PATH
# Add RubyGems to PATH
2024-06-11 20:14:38 +02:00
if hash ruby 2> /dev/null; then
2023-02-15 12:29:55 +01:00
PATH="$(ruby -e 'print Gem.user_dir')/bin:$PATH"
fi
# Set compose to menu, kill X with ctrl-alt-backspace,
# disable nbsp (still available with compose-space-space)
setxkbmap -option compose:menu -option terminate:ctrl_alt_bksp -option nbsp:none
# Removes duplicates from $PATH. Copied from https://unix.stackexchange.com/a/14896
PATH=$(echo "$PATH" | awk -v RS=':' -v ORS=":" '!a[$1]++{if (NR > 1) printf ORS; printf $a[$1]}')
# Start gpg-agent
# Ubuntu (MATE) 18.04 doesn't appreciate this
#eval $(gpg-agent --daemon)
# Enable core files.
ulimit -c unlimited
2015-12-15 19:05:55 +01:00
# Numlock on at boot
2024-06-11 20:14:38 +02:00
if hash numlockx 2> /dev/null; then
2023-02-15 12:29:55 +01:00
numlockx on
fi
# Workaround disappearing cursors, probably no harm in any case
export XCURSOR_DISCOVER=1
# The environment was set to ~/.environment according to other files...
if [ -f ~/.environment ]; then
2023-02-15 12:29:55 +01:00
. ~/.environment
fi
2021-02-27 21:48:22 +01:00
# Something that scripts here won't attempt to overwrite
if [ -f ~/.environment2 ]; then
2023-02-15 12:29:55 +01:00
. ~/.environment2
2021-02-27 21:48:22 +01:00
fi