Compare commits
No commits in common. "946a694d6e248437180585acf2d5ae72cae25074" and "87eb242cf0a827781f846204276daa5237d7dd2c" have entirely different histories.
946a694d6e
...
87eb242cf0
19
.bashrc
19
.bashrc
@ -119,22 +119,17 @@ fi
|
|||||||
EDITOR=/usr/bin/vim.basic
|
EDITOR=/usr/bin/vim.basic
|
||||||
PAGER="less"
|
PAGER="less"
|
||||||
LESS="-S"
|
LESS="-S"
|
||||||
|
|
||||||
export IPTOKEN="6ac0a563fc06ab"
|
export IPTOKEN="6ac0a563fc06ab"
|
||||||
export PG="psql -U ptrowbridge -d ubm -p 5432 -h 192.168.1.110"
|
export PG="psql -U ptrowbridge -d ubm -p 5432 -h 192.168.1.110"
|
||||||
export PGD="psql -U ptrowbridge -d ubm -p 5434 -h 192.168.1.110"
|
|
||||||
export NVM_DIR="/home/pt/.nvm"
|
export NVM_DIR="/home/pt/.nvm"
|
||||||
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
|
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
|
||||||
|
|
||||||
|
|
||||||
#GOPATH=$HOME/go
|
GOPATH=$HOME/go
|
||||||
#function _update_ps1() {
|
function _update_ps1() {
|
||||||
# PS1="$($GOPATH/bin/powerline-go -error $?)"
|
PS1="$($GOPATH/bin/powerline-go -error $?)"
|
||||||
#}
|
}
|
||||||
#if [ "$TERM" != "linux" ] && [ -f "$GOPATH/bin/powerline-go" ]; then
|
if [ "$TERM" != "linux" ] && [ -f "$GOPATH/bin/powerline-go" ]; then
|
||||||
# PROMPT_COMMAND="_update_ps1; $PROMPT_COMMAND"
|
PROMPT_COMMAND="_update_ps1; $PROMPT_COMMAND"
|
||||||
#fi
|
fi
|
||||||
|
|
||||||
#deno
|
|
||||||
export DENO_INSTALL="/home/pt/.deno"
|
|
||||||
export PATH="$DENO_INSTALL/bin:$PATH"
|
|
||||||
|
@ -5,8 +5,6 @@ bind -r j select-pane -D # move down
|
|||||||
bind -r k select-pane -U # move up
|
bind -r k select-pane -U # move up
|
||||||
bind -r l select-pane -R # move right
|
bind -r l select-pane -R # move right
|
||||||
|
|
||||||
set -g mouse on
|
|
||||||
|
|
||||||
#plugin manager for install tmux-resurrect
|
#plugin manager for install tmux-resurrect
|
||||||
set -g @plugin 'tmux-plugins/tpm'
|
set -g @plugin 'tmux-plugins/tpm'
|
||||||
set -g @plugin 'tmux-plugins/tmux-resurrect'
|
set -g @plugin 'tmux-plugins/tmux-resurrect'
|
||||||
|
15
.vimrc
15
.vimrc
@ -8,6 +8,7 @@ call vundle#begin()
|
|||||||
Plugin 'gmarik/Vundle.vim'
|
Plugin 'gmarik/Vundle.vim'
|
||||||
Plugin 'vim-airline/vim-airline'
|
Plugin 'vim-airline/vim-airline'
|
||||||
Plugin 'kien/ctrlp.vim'
|
Plugin 'kien/ctrlp.vim'
|
||||||
|
Plugin 'tpop/vim-fugitive'
|
||||||
Plugin 'scrooloose/nerdtree'
|
Plugin 'scrooloose/nerdtree'
|
||||||
Plugin 'edkolev/tmuxline.vim'
|
Plugin 'edkolev/tmuxline.vim'
|
||||||
Plugin 'vim-airline/vim-airline-themes'
|
Plugin 'vim-airline/vim-airline-themes'
|
||||||
@ -21,7 +22,7 @@ map <C-k> <C-W>k
|
|||||||
map <C-h> <C-W>h
|
map <C-h> <C-W>h
|
||||||
map <C-l> <C-W>l
|
map <C-l> <C-W>l
|
||||||
let NERDTreeShowHidden=1
|
let NERDTreeShowHidden=1
|
||||||
set tabstop=4 softtabstop=0 expandtab shiftwidth=4 smarttab
|
set tabstop=8 softtabstop=0 expandtab shiftwidth=4 smarttab
|
||||||
colorscheme desert
|
colorscheme desert
|
||||||
syntax on
|
syntax on
|
||||||
set splitright
|
set splitright
|
||||||
@ -36,16 +37,13 @@ let g:netrw_winsize = 25
|
|||||||
"----airline tabs for buffers-------
|
"----airline tabs for buffers-------
|
||||||
let g:airline#extensions#tabline#enabled = 1
|
let g:airline#extensions#tabline#enabled = 1
|
||||||
let g:airline_theme = 'dark'
|
let g:airline_theme = 'dark'
|
||||||
let g:tmuxline_powerline_separators = 0
|
let g:tmuxline_powerline_separators = 1
|
||||||
let g:airline_powerline_fonts = 0
|
let g:airline_powerline_fonts = 1
|
||||||
let mapleader = ";"
|
let mapleader = ";"
|
||||||
set showcmd
|
set showcmd
|
||||||
map <Leader>a :bn<cr>
|
map <Leader>a :bn<cr>
|
||||||
map <Leader>f :bp<cr>
|
map <Leader>f :bp<cr>
|
||||||
map <Leader>d :bp<cr>:bd #<cr>
|
map <Leader>d :bp<cr>:bd #<cr>
|
||||||
"---move the whole page without moving the cursor---
|
|
||||||
nnoremap J <C-E>
|
|
||||||
nnoremap K <C-Y>
|
|
||||||
"-----nerdtree--------------------
|
"-----nerdtree--------------------
|
||||||
nmap <Leader>e :NERDTreeToggle<CR>
|
nmap <Leader>e :NERDTreeToggle<CR>
|
||||||
" Search as you type, highlight results
|
" Search as you type, highlight results
|
||||||
@ -54,8 +52,3 @@ set showmatch
|
|||||||
set hlsearch
|
set hlsearch
|
||||||
nnoremap \\ :noh<cr> " Clear higlighting
|
nnoremap \\ :noh<cr> " Clear higlighting
|
||||||
"nnoremap <esc> :noh<return><esc>
|
"nnoremap <esc> :noh<return><esc>
|
||||||
" Resize windows
|
|
||||||
nnoremap <silent> <Up> 5<C-W>+
|
|
||||||
nnoremap <silent> <Down> 5<C-W>-
|
|
||||||
nnoremap <silent> <Right> 10<C-W>>
|
|
||||||
nnoremap <silent> <Left> 10<C-W><
|
|
||||||
|
71
setup.sh
71
setup.sh
@ -7,38 +7,6 @@ dir=~/dot_config
|
|||||||
backup=~/dot_config_backup
|
backup=~/dot_config_backup
|
||||||
files=".bashrc .vimrc .tmux.conf .psqlrc .gitconfig"
|
files=".bashrc .vimrc .tmux.conf .psqlrc .gitconfig"
|
||||||
|
|
||||||
#-------------------------------------------------install debian tooling-----------------------------------------------------------------------------------
|
|
||||||
|
|
||||||
#----------curl-----------
|
|
||||||
if [ "$(dpkg-query -W -f='${Status}' "curl" 2>/dev/null | grep -c "ok installed")" == "1" ]
|
|
||||||
then
|
|
||||||
echo "curl already installed"
|
|
||||||
else
|
|
||||||
echo "installing curl"
|
|
||||||
apt update -q4
|
|
||||||
apt install curl -y
|
|
||||||
fi
|
|
||||||
|
|
||||||
#----------vim-----------
|
|
||||||
if [ "$(dpkg-query -W -f='${Status}' "curl" 2>/dev/null | grep -c "ok installed")" == "1" ]
|
|
||||||
then
|
|
||||||
echo "vim already installed"
|
|
||||||
else
|
|
||||||
echo "installing vim"
|
|
||||||
apt update -q4
|
|
||||||
apt install vim -y
|
|
||||||
fi
|
|
||||||
|
|
||||||
#----------tmux-----------
|
|
||||||
if [ "$(dpkg-query -W -f='${Status}' "tmux" 2>/dev/null | grep -c "ok installed")" == "1" ]
|
|
||||||
then
|
|
||||||
echo "tmux already installed"
|
|
||||||
else
|
|
||||||
echo "installing tmux"
|
|
||||||
apt update -q4
|
|
||||||
apt install tmux -y
|
|
||||||
fi
|
|
||||||
|
|
||||||
#------------------------------------------------ create the resore directory if it doesn't already exist--------------------------------------------------
|
#------------------------------------------------ create the resore directory if it doesn't already exist--------------------------------------------------
|
||||||
|
|
||||||
if [ ! -d $backup ]
|
if [ ! -d $backup ]
|
||||||
@ -64,17 +32,17 @@ done
|
|||||||
|
|
||||||
#----------------------------------------------------------install go and go-powerline--------------------------------------------------------------------
|
#----------------------------------------------------------install go and go-powerline--------------------------------------------------------------------
|
||||||
|
|
||||||
# if $GOPATH is null the prompt for golang install
|
|
||||||
if [ -z "$GOPATH" ]
|
if [ -z "$GOPATH" ]
|
||||||
then
|
then
|
||||||
while true; do
|
while true; do
|
||||||
read -p "do you want to install golang (needed for go-powerline)?" yn
|
read -p "do you want to install golang and go-powerline?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* )
|
[Yy]* )
|
||||||
sudo apt-get install golang -y;
|
sudo apt-get install golang -y;
|
||||||
|
go get -u github.com/justjanne/powerline-go;
|
||||||
break;;
|
break;;
|
||||||
[Nn]* )
|
[Nn]* )
|
||||||
break;;
|
exit;;
|
||||||
* ) echo "Please answer yes or no.";;
|
* ) echo "Please answer yes or no.";;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
@ -82,28 +50,27 @@ fi
|
|||||||
|
|
||||||
#----------------------------------------------------------install go-powerline---------------------------------------------------------------------------
|
#----------------------------------------------------------install go-powerline---------------------------------------------------------------------------
|
||||||
|
|
||||||
# see if this file exists, if not prompt for install
|
if [ -z "$GOPATH" ]
|
||||||
if [ ! -f ~/go/bin/powerline-go ]
|
|
||||||
then
|
then
|
||||||
while true; do
|
while true; do
|
||||||
read -p "do you want to install go-powerline?" yn
|
read -p "do you want to install golang and go-powerline?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* )
|
[Yy]* )
|
||||||
|
sudo apt-get install golang -y;
|
||||||
go get -u github.com/justjanne/powerline-go;
|
go get -u github.com/justjanne/powerline-go;
|
||||||
break;;
|
break;;
|
||||||
[Nn]* )
|
[Nn]* )
|
||||||
break;;
|
exit;;
|
||||||
* ) echo "Please answer yes or no.";;
|
* ) echo "Please answer yes or no.";;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#----------------------------------------------------------install power line fonts------------------------------------------------------------------------
|
#----------------------------------------------------------install power line fonts------------------------------------------------------------------------
|
||||||
|
|
||||||
if [ ! -d ~/fonts ]
|
if [ ! -d ~/fonts ]
|
||||||
then
|
then
|
||||||
while true; do
|
while true; do
|
||||||
read -p "do you want to install powerline fonts from 'https://github.com/powerline/fonts' ?" yn
|
read -p "do you want to install powerline fonts from https://github.com/powerline/fonts?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* )
|
[Yy]* )
|
||||||
git clone https://github.com/powerline/fonts ~/fonts;
|
git clone https://github.com/powerline/fonts ~/fonts;
|
||||||
@ -111,7 +78,7 @@ then
|
|||||||
./install.sh;
|
./install.sh;
|
||||||
break;;
|
break;;
|
||||||
[Nn]* )
|
[Nn]* )
|
||||||
break;;
|
exit;;
|
||||||
* ) echo "Please answer yes or no.";;
|
* ) echo "Please answer yes or no.";;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
@ -123,13 +90,13 @@ fi
|
|||||||
if [ ! -d ~/.tmux/plugins/tpm ]
|
if [ ! -d ~/.tmux/plugins/tpm ]
|
||||||
then
|
then
|
||||||
while true; do
|
while true; do
|
||||||
read -p "do you want to install the tmux plugin manager from 'https://github.com/tmux-plugins/tpm' ?" yn
|
read -p "do you want to install the tmux plugin manager from https://github.com/tmux-plugins/tpm" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* )
|
[Yy]* )
|
||||||
git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm;
|
git clone https://github.com/tmux-plugins/tpm ~/.tmux/plugins/tpm;
|
||||||
break;;
|
break;;
|
||||||
[Nn]* )
|
[Nn]* )
|
||||||
break;;
|
exit;;
|
||||||
* ) echo "Please answer yes or no.";;
|
* ) echo "Please answer yes or no.";;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
@ -138,26 +105,16 @@ fi
|
|||||||
|
|
||||||
#----------------------------------------------------------see if Vundle has been cloned yet and do so-----------------------------------------------------
|
#----------------------------------------------------------see if Vundle has been cloned yet and do so-----------------------------------------------------
|
||||||
|
|
||||||
if [ ! -d ~/.vim/bundle ]
|
if [ ! -d ~/.vim ]
|
||||||
then
|
then
|
||||||
while true; do
|
|
||||||
read -p "do you want to install the Vundle plugin manager for vim from https://github.com/VundleVim/Vundle.vim.git?" yn
|
|
||||||
case $yn in
|
|
||||||
[Yy]* )
|
|
||||||
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
|
git clone https://github.com/VundleVim/Vundle.vim.git ~/.vim/bundle/Vundle.vim
|
||||||
# ask to install plugins after vundle installed
|
|
||||||
while true; do
|
while true; do
|
||||||
read -p "Do you want to install the vim plugins now?" yn
|
read -p "Do you want to install the vim plugins now?" yn
|
||||||
case $yn in
|
case $yn in
|
||||||
[Yy]* ) vim +PluginInstall +qall; break;;
|
[Yy]* ) vim +PluginInstall +qall; break;;
|
||||||
[Nn]* ) break;;
|
[Nn]* ) exit;;
|
||||||
* ) echo "Please answer yes or no.";;
|
|
||||||
esac
|
|
||||||
done
|
|
||||||
break;;
|
|
||||||
[Nn]* )
|
|
||||||
break;;
|
|
||||||
* ) echo "Please answer yes or no.";;
|
* ) echo "Please answer yes or no.";;
|
||||||
esac
|
esac
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
|
echo "you may need to run vim and execute :PluginInstall to sync packages with the new .vimrc, or \"vim +PluginInstall +qall\" from the command line"
|
||||||
|
Loading…
Reference in New Issue
Block a user