update bash environment and remove completion scripts in favor of keeping those in projects

master
Andrew Coleman 2020-10-30 12:06:17 -04:00
parent 207ef573b2
commit 7f65f95a04
10 changed files with 51 additions and 11516 deletions

56
.bashrc
View File

@ -1,19 +1,58 @@
# If not running interactively, don't do anything
case $- in
*i*) ;;
*) return;;
esac
test -f /etc/bashrc && . /etc/bashrc || true test -f /etc/bashrc && . /etc/bashrc || true
test -f /etc/bash.bashrc && . /etc/bash.bashrc || true test -f /etc/bash.bashrc && . /etc/bash.bashrc || true
test -f /etc/bash_completion && . /etc/bash_completion || true test -f /etc/bash_completion && . /etc/bash_completion || true
[[ -r "/usr/local/etc/profile.d/bash_completion.sh" ]] && . "/usr/local/etc/profile.d/bash_completion.sh" [[ -r "/usr/local/etc/profile.d/bash_completion.sh" ]] && . "/usr/local/etc/profile.d/bash_completion.sh"
test -f $HOME/.bash_aliases && . $HOME/.bash_aliases || true test -f $HOME/.bash_aliases && . $HOME/.bash_aliases || true
test -f $HOME/.cargo/env && . $HOME/.cargo/env || true test -f $HOME/.cargo/env && . $HOME/.cargo/env || true
if [ -e $HOME/.nix-profile/etc/profile.d/nix.sh ]; then . $HOME/.nix-profile/etc/profile.d/nix.sh; fi
export GIT_MERGE_AUTOEDIT=no EDITOR=vim
export EDITOR=vim PATH=$PATH:$HOME/.local/bin:$HOME/bin
export PATH=$PATH:$HOME/.local/bin:$HOME/bin GIT_MERGE_AUTOEDIT=no
HISTSIZE=5000 # don't put duplicate lines or lines starting with space in the history.
# See bash(1) for more options
HISTCONTROL=ignoreboth
# No locking on Ctrl-S
stty -ixon
# check the window size after each command and, if necessary,
# update the values of LINES and COLUMNS.
shopt -s checkwinsize
# enable color support of ls and also add handy aliases
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
alias grep='grep --color=auto'
alias fgrep='fgrep --color=auto'
alias egrep='egrep --color=auto'
fi
##
## history: http://mywiki.wooledge.org/BashFAQ/088
##
# Big history
HISTFILESIZE=10000 HISTFILESIZE=10000
HISTSIZE=10000
HISTTIMEFORMAT="%Y-%m-%d %H:%M:%S " HISTTIMEFORMAT="%Y-%m-%d %H:%M:%S "
for k in $HOME/bin/*.bash ; do . $k ; done # history -a causes an immediate write of all new history lines
# (instead of upon shell exit)
PROMPT_COMMAND="history -a"
# histappend which causes all new history lines to be appended, and ensures
# that multiple logins do not overwrite each other's history
shopt -s histappend
function _update_ps1() { function _update_ps1() {
PS1="$(powerline-go -error $?)" PS1="$(powerline-go -error $?)"
@ -23,3 +62,10 @@ if [[ $(which powerline-go 2>/dev/null) && "$TERM" != "linux" && "$TERM_PROGRAM"
else else
PS1='[\[\033[01;32m\]\u@\h\[\033[00m\] \[\033[01;34m\]\w$(__git_ps1 " (%s)")\[\033[00m\]]\$ ' PS1='[\[\033[01;32m\]\u@\h\[\033[00m\] \[\033[01;34m\]\w$(__git_ps1 " (%s)")\[\033[00m\]]\$ '
fi fi
for i in $HOME/bin/*.bash ; do
. $i
done
# Set up direnv
eval "$(direnv hook bash)"

View File

@ -1,4 +0,0 @@
#!/bin/bash
if [[ "$TERM" == "screen" ]] ; then
export TERM=xterm-256color
fi

File diff suppressed because it is too large Load Diff

View File

@ -1,2 +0,0 @@
#!/bin/bash
test -s "$HOME/.kerl/installs/22.0/activate" && . "$HOME/.kerl/installs/22.0/activate"

View File

@ -1,2 +0,0 @@
test -s "$HOME/.kiex/scripts/kiex" && source "$HOME/.kiex/scripts/kiex"
test -s "$HOME/.kiex/elixirs/elixir-1.9.1.env" && source "$HOME/.kiex/elixirs/elixir-1.9.1.env"

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +0,0 @@
_kube_contexts()
{
local curr_arg;
curr_arg=${COMP_WORDS[COMP_CWORD]}
COMPREPLY=( $(compgen -W "- $(kubectl config get-contexts --output='name')" -- $curr_arg ) );
}
complete -F _kube_contexts kubectx kctx

View File

@ -1,8 +0,0 @@
_kube_namespaces()
{
local curr_arg;
curr_arg=${COMP_WORDS[COMP_CWORD]}
COMPREPLY=( $(compgen -W "- $(kubectl get namespaces -o=jsonpath='{range .items[*].metadata.name}{@}{"\n"}{end}')" -- $curr_arg ) );
}
complete -F _kube_namespaces kubens kns

View File

@ -1 +0,0 @@
export VAGRANT_DEFAULT_PROVIDER=libvirt