29 lines
976 B
Plaintext
Executable File
29 lines
976 B
Plaintext
Executable File
# Start GPG and SSH agents
|
|
export GPG_TTY=$(tty)
|
|
eval $(gpg-agent --daemon --enable-ssh-support --write-env-file "${HOME}/.gpg-agent-info")
|
|
if [ -f "${HOME}/.gpg-agent-info" ]; then
|
|
# gpg-agent[****]: WARNING: "--write-env-file" is an obsolete
|
|
# option - it has no effect
|
|
. "${HOME}/.gpg-agent-info"
|
|
export GPG_AGENT_INFO
|
|
export SSH_AUTH_SOCK
|
|
export SSH_AGENT_PID
|
|
else
|
|
echo "Howdy, user ID ${EUID}. Shenanigans beget shenanigans."
|
|
# not needed this because we have .ssh/config
|
|
# but keep this uncommented because Git is being
|
|
# an dougebag in every single shell sessiob.
|
|
source ~/.dotfiles/bin/source-ssh-agent
|
|
fi
|
|
|
|
# Then add my scripts
|
|
export DOTFILES_STUFF_BIN="$HOME/.dotfiles/bin"
|
|
export PATH=$PATH:$DOTFILES_STUFF_BIN
|
|
|
|
# clean up bash history
|
|
echo
|
|
history -c && echo "history-cleanup: Shell history cleaned for past session" || echo "history-cleanup: No bash_history file found for past session."
|
|
|
|
# add my aliases
|
|
source ~/.dotfiles/bashrc/aliases
|