2013-03-23 14:48:31 +01:00
|
|
|
# ~/.bashrc: executed by bash(1) for non-login shells.
|
|
|
|
# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)
|
|
|
|
# for examples
|
|
|
|
|
|
|
|
# If not running interactively, don't do anything
|
|
|
|
[ -z "$PS1" ] && return
|
|
|
|
|
2015-02-13 18:31:43 +01:00
|
|
|
shopt -s checkwinsize
|
|
|
|
shopt -s histappend
|
|
|
|
export HISTCONTROL=ignoredups
|
|
|
|
export CLICOLOR=1
|
2015-10-17 10:43:06 +02:00
|
|
|
export EDITOR='vim'
|
2015-02-13 18:31:43 +01:00
|
|
|
export PAGER='less'
|
2013-03-23 14:48:31 +01:00
|
|
|
export USER_NICKNAME="Rodolphe Breard"
|
2015-02-13 18:31:43 +01:00
|
|
|
export DEBEMAIL="packages+deb@what.tf"
|
2013-03-23 14:48:31 +01:00
|
|
|
export DEBFULLNAME="$USER_NICKNAME"
|
2017-02-12 16:09:16 +01:00
|
|
|
|
|
|
|
# Path
|
|
|
|
[ -f ~/.setpath.sh ] && . ~/.setpath.sh
|
2013-04-24 17:16:14 +02:00
|
|
|
|
2013-03-23 14:48:31 +01:00
|
|
|
# Colors
|
2015-02-13 18:31:43 +01:00
|
|
|
[ "$CLICOLOR" -ne 0 ] && hash dircolors 2>/dev/null && eval $(dircolors -b)
|
2013-03-23 14:48:31 +01:00
|
|
|
|
2015-02-13 18:31:43 +01:00
|
|
|
# Command completion
|
|
|
|
[ -f /etc/bash_completion ] && . /etc/bash_completion
|
2013-04-01 22:18:46 +02:00
|
|
|
|
2015-02-13 18:31:43 +01:00
|
|
|
# Prompt
|
2015-10-20 13:52:26 +02:00
|
|
|
if [ -f "/usr/bin/liquidprompt" ]; then
|
2014-01-14 12:23:34 +01:00
|
|
|
unset PROMPT_COMMAND
|
2015-10-20 13:52:26 +02:00
|
|
|
. "/usr/bin/liquidprompt"
|
2014-08-26 11:38:49 +02:00
|
|
|
elif [ -f "$HOME/liquidprompt/liquidprompt" ]; then
|
|
|
|
unset PROMPT_COMMAND
|
2015-02-13 18:31:43 +01:00
|
|
|
. "$HOME/liquidprompt/liquidprompt"
|
2015-10-20 13:52:26 +02:00
|
|
|
elif [ "$CLICOLOR" -ne 0 ]; then
|
|
|
|
PS1="\[\033[01;31m\]\u\[\033[01;37m\]@\[\033[01;33m\]\h\[\033[01;31m\]->\[\033[00m\] "
|
2014-01-14 12:23:34 +01:00
|
|
|
else
|
2015-10-20 13:52:26 +02:00
|
|
|
PS1='\u@\h-> '
|
2013-03-23 14:48:31 +01:00
|
|
|
fi
|
2013-08-23 11:43:48 +02:00
|
|
|
|
2013-11-13 15:39:59 +01:00
|
|
|
# GPG Agent
|
|
|
|
export GPG_TTY=$(tty)
|
2016-06-28 23:14:30 +02:00
|
|
|
[ -S "/run/user/${UID}/gnupg/S.gpg-agent" ] && export GPG_AGENT_INFO="/run/user/${UID}/gnupg/S.gpg-agent"
|
|
|
|
[ -S "/run/user/${UID}/gnupg/S.gpg-agent.ssh" ] && export SSH_AUTH_SOCK="/run/user/${UID}/gnupg/S.gpg-agent.ssh"
|
2016-06-28 23:09:07 +02:00
|
|
|
pgrep -x -u "${USER}" gpg-agent >/dev/null 2>&1 && export SSH_AGENT_PID=$(pgrep -x -u "${USER}" gpg-agent)
|
2015-02-13 18:31:43 +01:00
|
|
|
|
|
|
|
# Aliases
|
2015-11-02 23:47:10 +01:00
|
|
|
[ -f "$HOME/.aliases" ] && . "$HOME/.aliases"
|