-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.bashrc
57 lines (34 loc) · 1.17 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
#
# ~/.bashrc
#
# If not running interactively, don't do anything
[[ $- != *i* ]] && return
alias grep='grep --color=auto'
alias ls='ls --color=auto'
alias vi='vim'
alias regex101="pcregrep --buffer-size=200000 -Mo"
alias man="vilman"
alias myip="nslookup -debug myip.opendns.com resolver1.opendns.com | grep 'internet address' | sed 's/.*internet address =/My Public IP Address:/g'"
#alias kb="kubectl "
#source <(kubectl completion bash | sed 's|__start_kubectl kubectl|__start_kubectl kb|g')
alias p3="/usr/bin/python3"
alias pd="/usr/bin/podman"
source <(podman completion bash | sed 's|__start_podman podman|__start_podman pd|g')
PS1='\[\e[1;96m\]\u@\[\e[1;93m\]\h: \W
\$\[\033[1;92m\] '
#allow reverse search in back mode, pay attention with local scp could give issues
stty -ixon
export GOPATH=$HOME/go
export EDITOR=/usr/bin/vim
export HISTSIZE=10000
export HISTCONTROL=ignoredups:erasedups
function vilman {
vim -c "Man $1" -c "silent only"
}
function cd {
builtin cd $@
pwd > ~/.last_dir
}
cd $(cat ~/.last_dir)
trap 'printf "\033]0;%s\007" "${BASH_COMMAND//[^[:print:]]/}"' DEBUG
PROMPT_COMMAND='history -a; history -n; echo -ne "\033]0;${PWD}\007"'