-
Notifications
You must be signed in to change notification settings - Fork 1
/
bashrc
62 lines (53 loc) · 1.84 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
#
# ~/.bashrc
#
# If not running interactively, don't do anything
[[ $- != *i* ]] && return
source ~/.git-prompt.sh
export PS1='\[\e[34m\]┌[\[\e[32m\]\u\[\e[35m\]@\[\e[36m\]\H\[\e[34m\]]-[\[\e[35m\]\t\[\e[34m\]]-[\[\e[33m\]\w\[\e[34m\]]\[\e[0m\]$(echo -e "$(__git_ps1)") $DEF_PROXY \n\[\e[34m\]└[\[\e[35m\]\$\[\e[34m\]]\[\e[0m\] '
export TERM=xterm-256color
alias ssh='TERM=xterm-256color /usr/bin/ssh'
# replaced utils
alias ls='/usr/bin/eza --icons=auto'
alias ll='/usr/bin/eza -bghHliS --icons=auto'
alias grep='/usr/bin/rg'
alias ncdu='/usr/bin/ncdu --color=dark'
alias ping='/usr/bin/prettyping'
alias cat='/usr/bin/bat'
alias diff='delta'
# bat
export BAT_PAGER="less -RF"
export BAT_THEME=OneHalfDark
# fzf
export FZF_CTRL_T_OPTS="
--walker-skip .git,node_modules,target
--preview 'bat -n --color=always {}'
--bind 'ctrl-/:change-preview-window(down|hidden|)'
--bind 'enter:become(vim {})'"
export FZF_CTRL_R_OPTS="
--preview 'echo {}' --preview-window up:3:hidden:wrap
--bind 'ctrl-/:toggle-preview'
--color header:italic"
export FZF_ALT_C_OPTS="
--walker-skip .git,node_modules,target
--preview 'tree -C {}'"
# extend utils
source ~/.ranger-cd.sh
for c in $(ls ~/.local/share/bash-completion/*); do
source $c
done
alias ssp='source setproxy.sh'
alias bmpv='/usr/local/bin/xwinwrap -ni -fs -s -st -sp -b -nf -ov -- mpv -wid WID'
alias engit='source ~/.git-prompt.sh'
alias disgit='__git_ps1() { echo " (disabled)"; }'
alias enrustup='export PATH=/home/remilia/.rustup/bin:$PATH'
alias disrustup='export PATH=${PATH#/home/remilia/.rustup/bin:}'
alias py='/usr/bin/ipython'
alias latexmk='latexmk -interaction=nonstopmode'
alias vims='/usr/bin/vim --servername VIM'
alias tig='/usr/bin/tig --date-order --all'
alias mutt_remilia='/usr/bin/mutt -F /home/remilia/.mutt/[email protected]/muttrc'
# tool
set_title() {
echo -en "\e]0;$@\a"
}