test

XXX

 #!/bin/bash                                                                                                                                                               
  1  
  2 # refer  spf13-vim bootstrap.sh`
  3 BASEDIR=$(dirname $0)
  4 cd $BASEDIR
  5 CURRENT_DIR=`pwd`
  6  
  7 lnif() {
  8     if [ -e "$1" ]; then
  9         ln -sf "$1" "$2"
 10     fi
 11 }
 12  
 13 echo "Step1: backing up current vim config"
 14 today=`date +%Y%m%d`
 15 for i in $HOME/.vim $HOME/.vimrc $HOME/.gvimrc $HOME/.vimrc.bundles; do [ -e $i ] && [ ! -L $i ] && mv $i $i.$today; done
 16 for i in $HOME/.vim $HOME/.vimrc $HOME/.gvimrc $HOME/.vimrc.bundles; do [ -L $i ] && unlink $i ; done
 17  

 

posted on 2015-07-26 14:21  扶朕起来,朕还能送  阅读(195)  评论(0编辑  收藏  举报

导航