-
Notifications
You must be signed in to change notification settings - Fork 2
/
root_profile
49 lines (42 loc) · 1.45 KB
/
root_profile
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
export LC_ALL=en_US.UTF-8
PS1="sudo $ \W :. "
export PATH="/usr/local/bin:/usr/local/sbin:$PATH"
export CLICOLOR=1
# History
export HISTCONTROL=ignoreboth:erasedups
export HISTSIZE=100000
export HISTFILESIZE=100000
# custom prompt command to share history between panes but still allow isolated history in each tmux pane
#
# turn off histappend in case it is set
shopt -u histappend
# 1) append new commands TO the history file since session started
# 2) append new commands FROM the history file since session started
# 3) write session history TO the history file
# 4) clear the session history
# 5) read the history file into the history list
export PROMPT_COMMAND="history -a; history -n; history -w; history -c; history -r;"
# Aliases
alias ..="cd .."
alias open="xdg-open"
alias gs="git status"
# Fuzzy finder FZF
export FZF_DEFAULT_OPTS='--bind "alt-a:select-all,alt-d:deselect-all"'
export FZF_DEFAULT_COMMAND='ag --hidden --ignore .git -g ""'
export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
if [ -d $HOME/neovim ]; then
export PATH="$HOME/neovim/usr/bin:$PATH"
else
if [ -x "$(command -v curl)" ]; then
echo "#################"
echo "INSTALLING Neovim"
echo "#################"
echo ""
curl -LO https://github.com/neovim/neovim/releases/download/stable/nvim.appimage
chmod +x nvim.appimage
./nvim.appimage --appimage-extract
mv squashfs-root $HOME/neovim
rm nvim.appimage
export PATH="$HOME/neovim/usr/bin:$PATH"
fi
fi