From cdc43ca60fa649f4c723683d23ad0f2cc75ca760 Mon Sep 17 00:00:00 2001 From: Austen Date: Mon, 16 Jun 2014 23:13:57 -0400 Subject: [PATCH] Removed synapse from desktop.txt. Fixed in insert mode in vimrc. Fixed sync.sh flags for the last time! (hopefully) --- desktop.txt | 3 +- sync.sh | 121 ++++++++++++++++++---------------------------------- vimrc | 2 +- 3 files changed, 45 insertions(+), 81 deletions(-) diff --git a/desktop.txt b/desktop.txt index 6356049..5485d0f 100644 --- a/desktop.txt +++ b/desktop.txt @@ -1,6 +1,7 @@ #sudo apt-get update;sudo apt-get upgrade;sudo apt-get install $(grep -vE "^\s*#" apps.txt | tr "\n" " ") #apt-get remove ubuntuone* python3-oneconf -synapse +#Synapse removed because deb is not present in current repos :( +#synapse synaptic #python3.2 python-pip diff --git a/sync.sh b/sync.sh index 97d1827..c68ea1b 100755 --- a/sync.sh +++ b/sync.sh @@ -1,87 +1,50 @@ -#Install server applications -while getopts :s option -do - case "$option" in - s) - echo "Preparing server installation" - sudo apt-get update;sudo apt-get upgrade;sudo apt-get install $(grep -vE "^\s*#" server.txt | tr "\n" " ") - ;; - esac -done -#Install desktop applications -while getopts :d option -do - case "$option" in - d) - echo "Installing desktop applications" - sudo apt-get update;sudo apt-get upgrade;sudo apt-get install $(grep -vE "^\s*#" desktop.txt | tr "\n" " ") - ;; - esac -done -#Tmux sync -while getopts :t option -do - case "$option" in - t) - echo "Syncing tmux" - trash ~/.tmux.conf - ln -s ${PWD}/tmux.conf ~/.tmux.conf - ;; - esac -done -#Quit if -o is called -while getopts :o option -do - case "$option" in - o) - echo "Exiting" - exit 0 - ;; - esac -done rm ~/.gitconfig ~/.vimrc ~/.vimperatorrc ~/.gitignore_global ~/.bashrc ln -s ${PWD}/gitignore_global ~/.gitignore_global ln -s ${PWD}/vimrc ~/.vimrc ln -s ${PWD}/vimperatorrc ~/.vimperatorrc ln -s ${PWD}/gitconfig ~/.gitconfig ln -s ${PWD}/bashrc ~/.bashrc -if [ -f ~/.vim/plugin/ ] -then - echo "Installing plugin folder in ~/.vim/" - mkdir -p ~/.vim/plugin/ -fi -if [ -f ~/.vim/plugin/backup/ ] -then - echo "Installing backup folder in ~/.vim/" - mkdir -p ~/.vim/backup/ -fi -if [ -f ~/.vim/plugin/undo/ ] -then - echo "Installing undo folder in ~/.vim/" - mkdir -p ~/.vim/undo/ -fi -if [ -f ~/.vim/tmp/ ] -then - echo "Installing tmp folder in ~/.vim/" - mkdir -p ~/.vim/tmp/ -fi -if [ ! -f ~/.vim/plugin/sessionman.vim ] -then - echo "Installing sessionman in ~/.vim/plugin/" - wget -O ~/.vim/plugin/sessionman.vim http://www.vim.org/scripts/download_script.php?src_id=15599 -fi -#Install vim bundles -while getopts :b option -do - case "$option" in - b) - if [ -f ~/.vim/bundle/vundle/ ] - then - echo "Installing vundle" - git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle - fi - vim +BundleInstall +qa - ;; - esac +while getopts ":bsdto" VALUE "$@"; do + echo "Processing flag: $VALUE" + if [ "$VALUE" = "b" ] ; then + #Install vim bundles + mkdir -p ~/.vim/plugin/ + mkdir -p ~/.vim/backup/ + mkdir -p ~/.vim/undo/ + mkdir -p ~/.vim/tmp/ + mkdir -p ~/.vim/bundle/ + mkdir -p ~/.vim/bundle/ + echo "Installing vim bundles" + if [ ! -f ~/.vim/plugin/sessionman.vim ] + then + echo "Installing sessionman in ~/.vim/plugin/" + wget -O ~/.vim/plugin/sessionman.vim http://www.vim.org/scripts/download_script.php?src_id=15599 + fi + if [ ! -d ~/.vim/bundle/vundle/ ] + then + echo "Installing vundle" + git clone https://github.com/gmarik/vundle.git ~/.vim/bundle/vundle + fi + vim +BundleInstall +qa + fi + if [ "$VALUE" = "s" ] ; then + echo "Installing server applications:" + echo $(grep -vE "^\s*#" server.txt | tr "\n" " ") + sudo apt-get update;sudo apt-get upgrade;sudo apt-get install $(grep -vE "^\s*#" server.txt | tr "\n" " ") + fi + if [ "$VALUE" = "d" ] ; then + echo "Installing desktop applications" + echo $(grep -vE "^\s*#" desktop | tr "\n" " ") + sudo apt-get update;sudo apt-get upgrade;sudo apt-get install $(grep -vE "^\s*#" desktop.txt | tr "\n" " ") + fi + if [ "$VALUE" = "t" ] ; then + echo "Syncing tmux" + trash ~/.tmux.conf + ln -s ${PWD}/tmux.conf ~/.tmux.conf + fi + if [ "$VALUE" = "o" ] ; then + echo "Exiting because of -o flag" + exit 0 + fi done echo "Done syncing" diff --git a/vimrc b/vimrc index 2cecbf1..b8a25f7 100644 --- a/vimrc +++ b/vimrc @@ -151,7 +151,7 @@ let g:neocomplcache_force_overwrite_completefunc=1 let g:neocomplcache_min_syntax_length = 2 let g:php_refactor_command='php /usr/local/bin/refactor.phar' -inoremap neocomplcache#smart_close_popup()."\" +"inoremap neocomplcache#smart_close_popup()."\" "let g:neocomplcache_enable_auto_select = 1 let loaded_matchit = 1 set nocompatible " be iMproved