-
Notifications
You must be signed in to change notification settings - Fork 20
/
.bashrc
66 lines (53 loc) · 1.43 KB
/
.bashrc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
# shellcheck shell=bash
# Source global definitions
if [ -f /etc/bashrc ]; then
source /etc/bashrc
fi
# Enable MacPorts provided bash completions
if [ -f /opt/local/etc/profile.d/bash_completion.sh ]; then
source /opt/local/etc/profile.d/bash_completion.sh
fi
## User specific aliases and functions
# set up common env vars between bourne shells
source ~/.commonenv
# set up common aliases between bourne shells
source ~/.commonrc
# seriously, i want to use vi
set -o vi
# ^n cycle through the list of partial matches
bind -m vi-insert "\`":menu-complete
bind -m vi-insert "\C-a":beginning-of-line
bind -m vi-insert "\C-e":end-of-line
# history settings
export HISTFILE=$HOME/.bash_history
export HISTCONTROL=ignoreboth
export HISTSIZE=5000
export HISTFILESIZE=1000
# don't clear the history each time
shopt -s histappend
# Set up the prompt
if checkPath starship; then
eval "$(starship init bash)"
else
# Only show user in the prompt if it isn't yourself
# Make sure and set the $ME var
ME="clayton"
PR_IMPOSTER=""
if [ "$(whoami)" != $ME ]; then
PR_IMPOSTER="\n(\u)"
fi
# prompt will look like this:
#
# Tue Apr 28 00:38 | ~/Desktop
# clyde$
#
# and like this if I'm not me :)
#
# (notme)
# Tue Apr 28 00:38 | ~/Desktop
# clyde$
PS1="$PR_IMPOSTER\n\d \A | \w\n\h\$ "
fi
# load up server specific extras
source ~/.bash_extras
[ -f ~/.fzf.bash ] && source ~/.fzf.bash