2022-12-17 00:37:53 -05: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
|
|
|
|
|
2023-02-03 23:21:16 -05:00
|
|
|
# history settings
|
2023-02-01 01:12:30 -05:00
|
|
|
HISTSIZE=5000
|
|
|
|
HISTFILESIZE=10000
|
2023-02-03 23:21:16 -05:00
|
|
|
|
2023-02-01 01:12:30 -05:00
|
|
|
shopt -s histappend
|
2023-02-03 23:21:16 -05:00
|
|
|
|
2023-02-01 05:13:27 -05:00
|
|
|
PROMPT_COMMAND="history -a; $PROMPT_COMMAND"
|
2023-02-01 01:12:30 -05:00
|
|
|
|
2023-02-03 23:08:35 -05:00
|
|
|
export HISTCONTROL=erasedups
|
|
|
|
|
2022-12-17 00:37:53 -05:00
|
|
|
# check the window size after each command and, if necessary,
|
|
|
|
# update the values of LINES and COLUMNS.
|
|
|
|
shopt -s checkwinsize
|
|
|
|
|
|
|
|
# If set, the pattern "**" used in a pathname expansion context will
|
|
|
|
# match all files and zero or more directories and subdirectories.
|
|
|
|
shopt -s globstar
|
|
|
|
|
2023-02-03 23:25:38 -05:00
|
|
|
# automatically prepend cd when entering just a path in the shell
|
|
|
|
shopt -s autocd
|
|
|
|
|
2022-12-17 00:37:53 -05:00
|
|
|
# set a fancy prompt (non-color, unless we know we "want" color)
|
2022-12-27 19:12:25 -05:00
|
|
|
export TERM=xterm-color
|
2022-12-17 00:37:53 -05:00
|
|
|
|
|
|
|
# Alias definitions.
|
|
|
|
if [ -f ~/.bash_aliases ]; then
|
|
|
|
. ~/.bash_aliases
|
|
|
|
fi
|
|
|
|
|
|
|
|
# set PATH so it includes user's private bin if it exists
|
|
|
|
if [ -d "$HOME/bin" ] ; then
|
2023-01-07 02:51:06 -05:00
|
|
|
PATH="$HOME/bin:$PATH:$HOME/.local/bin"
|
2022-12-17 00:37:53 -05:00
|
|
|
fi
|
|
|
|
|
2023-02-04 00:50:10 -05:00
|
|
|
# source misc user scripts
|
2023-02-04 01:09:29 -05:00
|
|
|
#if [ -d ~/git/dotfiles/files ] ; then
|
|
|
|
# . ~/git/dotfiles/files/.*
|
|
|
|
#fi
|
2022-12-28 15:38:02 -05:00
|
|
|
|
2023-02-03 23:21:16 -05:00
|
|
|
# source headscale autocompletion script
|
2023-01-08 01:30:58 -05:00
|
|
|
if [ -f ~/.autoheadscale ] ; then
|
|
|
|
. ~/.autoheadscale
|
|
|
|
fi
|
2023-01-22 14:03:26 -05:00
|
|
|
|
2023-02-03 23:21:16 -05:00
|
|
|
# set prompt colors and style
|
2023-01-22 14:23:01 -05:00
|
|
|
if [ -f ~/.PS1 ] ; then
|
|
|
|
source ~/.PS1
|
2023-01-22 14:03:26 -05:00
|
|
|
else
|
|
|
|
PS1='\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]$ '
|
|
|
|
fi
|
2023-01-23 08:45:00 -05:00
|
|
|
|
2023-02-03 23:21:16 -05:00
|
|
|
# fetch uninstalled package names when attempting command (arch only)
|
|
|
|
if [ -f /usr/share/doc/pkgfile/command-not-found.bash ] ; then
|
|
|
|
source /usr/share/doc/pkgfile/command-not-found.bash
|
|
|
|
fi
|