Split out setup so I can do partial setups on servers
This commit is contained in:
parent
aa44fc6160
commit
69ac2f3b72
2 changed files with 54 additions and 0 deletions
20
setup-bash.sh
Executable file
20
setup-bash.sh
Executable file
|
@ -0,0 +1,20 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Clears out the old .bashrc
|
||||
if [ -f ~/.bashrc ];
|
||||
then
|
||||
rm ~/.bashrc
|
||||
fi
|
||||
|
||||
# Grabs the skeleton .bashrc
|
||||
cp /etc/skel/.bashrc ~/.bashrc
|
||||
|
||||
PWD=`pwd`
|
||||
|
||||
# Adds paths and custom .bashrc
|
||||
echo "
|
||||
export PATH=\"$PWD/git:$PATH\"
|
||||
|
||||
if [ -f $PWD/bashrc ] && ! shopt -oq posix; then
|
||||
. $PWD/bashrc
|
||||
fi" >> ~/.bashrc
|
34
setup-vim.sh
Executable file
34
setup-vim.sh
Executable file
|
@ -0,0 +1,34 @@
|
|||
#!/bin/bash
|
||||
|
||||
# Copies .vimrc
|
||||
if [ -f ~/.vimrc ];
|
||||
then
|
||||
rm ~/.vimrc
|
||||
fi
|
||||
|
||||
cp $PWD/vimrc ~/.vimrc
|
||||
|
||||
# Pulls down and installs vim plugins
|
||||
DOTVIM=~/.vim
|
||||
|
||||
if [ -d $DOTVIM ];
|
||||
then
|
||||
rm -r $DOTVIM
|
||||
fi
|
||||
|
||||
mkdir $DOTVIM
|
||||
|
||||
OWNERS=( "ervandew" "msanders" "nvie" "scrooloose" "scrooloose" "tpope" "vim-scripts" )
|
||||
REPOS=( "supertab" "snipmate.vim" "vim-togglemouse" "nerdtree" "syntastic" "vim-fugitive" "Command-T" )
|
||||
|
||||
for (( i = 0 ; i < ${#OWNERS[@]} ; i++ ))
|
||||
do
|
||||
git clone git://github.com/${OWNERS[$i]}/${REPOS[$i]}.git /tmp/${REPOS[$i]}
|
||||
cp -R /tmp/${REPOS[$i]}/* $DOTVIM
|
||||
rm -rf /tmp/${REPOS[$i]}
|
||||
done
|
||||
|
||||
# Finish up Command-T installation
|
||||
cd $DOTVIM/ruby/command-t
|
||||
ruby extconf.rb
|
||||
make
|
Loading…
Add table
Add a link
Reference in a new issue