From 9e2d84f357db4de5e0dd8a31ca1148b278b19be1 Mon Sep 17 00:00:00 2001 From: Bert Peters Date: Sat, 3 Jan 2015 22:03:07 +0100 Subject: [PATCH] Add an installation guide. --- README.md | 14 +++++++++++++- install.sh | 27 +++++++++++++++++++++++++++ 2 files changed, 40 insertions(+), 1 deletion(-) create mode 100755 install.sh diff --git a/README.md b/README.md index f94d6fc..9bc3e34 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,16 @@ vimconfig ========= -An attempt to normalize my Vim configuration across machines +An attempt to normalize my Vim configuration across machines. + +Installation +------------ + +To install this package as your local vim configuration, do the following: + +``` +git clone https://github.com/bertptrs/vimconfig.git ~/.vim +~/.vim/install.sh +``` + +This will install the correct vimrc and load the packages mentioned in bundle. diff --git a/install.sh b/install.sh new file mode 100755 index 0000000..ed2ac2d --- /dev/null +++ b/install.sh @@ -0,0 +1,27 @@ +#!/bin/bash + +if [ -f $HOME/.vimrc ] +then + echo "Already have a local vimrc, abort." + exit 1 +fi + +if [ ! -f $HOME/.vim/vimrc ] +then + echo "Vimconfig rc not found, abort." + exit 2 +fi + +echo "Installing .vimrc" +ln -s $HOME/.vim/vimrc $HOME/.vimrc + +echo -n "Downloading dependencies..." +cd $HOME/.vim + +git submodule init +git submodule update + +echo " Done" + +echo +echo "Installation finished."