-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathdot_bashrc
92 lines (73 loc) · 2.43 KB
/
dot_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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
# vi: ft=bash
# [[ $- == *i* ]] && [[ -f /usr/share/blesh/ble.sh ]] && source /usr/share/blesh/ble.sh --noattach && source ${XDG_CONFIG_HOME:-${HOME}/.config}/bash/ble-theme.sh
source ${XDG_CONFIG_HOME:-${HOME}/.config}/bash/aliases.sh
source ${XDG_CONFIG_HOME:-${HOME}/.config}/bash/options.sh
if has nvr; then
[ -z "$EDITOR" ] && export EDITOR="nvr -sl --remote-wait"
fi
if has nvim; then
[ -z "$MANPAGER" ] && export MANPAGER="nvim +Man!"
fi
[ -z "$VISUAL" ] && export VISUAL=$EDITOR
# export XDG_CURRENT_DESKTOP=Unity
export XKB_DEFAULT_LAYOUT=fr
# export XKB_DEFAULT_OPTIONS="caps:escape,altwin:swap_alt_win,lv3:rwin_switch"
if has bat; then
export PAGER=bat
fi
[ -f /usr/share/nvm/init-nvm.sh ] && source /usr/share/nvm/init-nvm.sh
[ -f $NVM_DIR/nvm.sh ] && source $NVM_DIR/nvm.sh
if has thefuck; then
export THEFUCK_EXCLUDE_RULES="fix_file"
eval $(thefuck --alias f)
fi
if has zoxide; then
eval "$(zoxide init bash)"
fi
[ -f "/usr/share/stderred/stderred.sh" ] && . "/usr/share/stderred/stderred.sh"
[ -f "/usr/share/stderred/stderred32.sh" ] && . "/usr/share/stderred/stderred32.sh"
if has npm; then
[[ -d "$HOME/.npm-packages/bin" ]] && export PATH="$HOME/.npm-packages/bin:$PATH"
fi
if has pnpm; then
[[ -d "$PNPM_HOME" ]] && export PATH="$PNPM_HOME:$PATH"
fi
if has pulumi; then
[[ -d "$PULUMI_HOME" ]] && export PATH="$PULUMI_HOME/bin:$PATH"
fi
if has cargo; then
[[ -d "$CARGO_HOME/bin" ]] && export PATH="$CARGO_HOME/bin:$PATH"
fi
if has go; then
[[ -d "$GOPATH/bin" ]] && export PATH="$GOPATH/bin:$PATH"
fi
if has pyvenv; then
[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"
eval "$(pyenv init -)"
fi
export PATH=$HOME/bin:$HOME/.local/bin:$PATH
if has direnv; then
eval "$(direnv hook bash)"
fi
[ -z "$GPG_TTY" ] && export GPG_TTY="$(tty)"
if has sk; then
export SKIM_CTRL_R_OPTS='--preview="echo {4..} | bat --plain --language zsh --color=always" --bind tab:accept'
source /usr/share/skim/key-bindings.bash
source /usr/share/skim/completion.bash
fi
if has rsnip; then
source <(rsnip --generate bash)
fi
if has starship; then
eval "$(starship init bash)"
fi
[[ $- == *i* ]] && [[ -f /usr/share/bash-completion/bash_completion ]] && \
source /usr/share/bash-completion/bash_completion
if has tmux; then
if [ -z "$TMUX" ] && (
[ "$TERM" = "xterm-kitty" ] || [ "$TERM" = "xterm-ghostty" ]
) then
tmux attach || exec tmux new-session && exit;
fi
fi
[[ ${BLE_VERSION-} ]] && ble-attach