2016-10-11 23:18:39 +02:00
|
|
|
# ~/.bash_profile
|
2016-09-26 18:11:51 +02:00
|
|
|
[ -z "$DOTFILES" ] && source "$HOME/.profile"
|
2016-10-02 23:39:11 +02:00
|
|
|
|
2022-02-10 20:15:22 +01:00
|
|
|
# Always source local bash_profiles
|
2016-10-02 23:39:11 +02:00
|
|
|
[ -r "$HOME/.bash_profile.local" ] && source "$HOME/.bash_profile.local"
|
2022-02-10 20:15:22 +01:00
|
|
|
[ -r "$HOME/.local/bash_profile" ] && source "$HOME/.local/bash_profile"
|
2016-10-11 23:18:39 +02:00
|
|
|
|
|
|
|
if shopt -q login_shell
|
|
|
|
then
|
|
|
|
# This is a bash login shell
|
|
|
|
LOGINHISTORY=~/.login.history
|
|
|
|
|
2022-02-10 20:15:22 +01:00
|
|
|
if [ -w "${LOGINHISTORY}" ]; then
|
|
|
|
echo "$(date) ${USER}@${HOSTNAME}" >> $LOGINHISTORY
|
|
|
|
fi
|
|
|
|
|
|
|
|
unset LOGINHISTORY
|
2016-10-11 23:18:39 +02:00
|
|
|
fi
|