From 315dd7104f02a278b9ade41345060ed5f6825fbb Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Mon, 6 Feb 2012 09:51:45 -0700 Subject: Added install script for vim support. --- support/vim/install.sh | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100755 support/vim/install.sh diff --git a/support/vim/install.sh b/support/vim/install.sh new file mode 100755 index 0000000..2a77b1b --- /dev/null +++ b/support/vim/install.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +for type in {ftdetect,ftplugin,syntax}/stage.vim; do + if [[ ! -e $type ]]; then + echo "You don't seem to be in the right directory." + echo "Run this from stage/support/vim" + exit + fi +done + +if [[ $(whoami) != "root" ]]; then + echo You should probably run this as root... + exit +fi + +for type in ftdetect ftplugin syntax; do + for dest in /usr/share/vim/vim*; do + if [[ ! -d $dest/$type ]]; then mkdir -v $dest/$type; fi + if [[ -e $dest/$type/stage.vim ]]; then rm -v $dest/$type/stage.vim; fi + cp -v $type/stage.vim $dest/$type + done +done -- cgit v1.2.3