-
Notifications
You must be signed in to change notification settings - Fork 12
/
catvimdir.sh
executable file
·43 lines (33 loc) · 1.16 KB
/
catvimdir.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
#!/bin/bash
source $(dirname $0)/config.sh
BASEDIR=$(cd $(dirname $BASH_SOURCE);pwd)
if [[ -h ~/.vim ]]; then
rm -rf ~/.vim
fi
if [[ ! -d ~/.vim ]]; then
mkdir -p ~/.vim/
fi
if [[ ! -r "$TEAM_BUNDLE_DIR" ]]; then
echo -e "---- 正在创建 $TEAM_BUNDLE_DIR , 请输入sudo 权限密码: ----\n"
sudo mkdir -p $TEAM_BUNDLE_DIR
sudo chmod 777 $TEAM_BUNDLE_DIR
fi
if [[ ! ~/.vim/team_bundle -ef "$TEAM_BUNDLE_DIR" ]]; then
echo -e "---- 更新 ~/.vim/team_bundle ----\n"
rm -rf ~/.vim/team_bundle
ln -s $TEAM_BUNDLE_DIR ~/.vim/team_bundle
fi
if [[ ! -r ~/.vim/team_bundle/Vundle.vim/ ]]; then
echo -e "---- 更新 ~/.vim/team_bundle/Vundle.vim ----\n"
git clone https://github.com/leiming/Vundle.vim.git ~/.vim/team_bundle/Vundle.vim/
fi
if [[ ! -r ~/.vim/team_bundle/pylon_ide/ ]]; then
echo -e "---- 更新 ~/.vim/team_bundle/pylon_ide ----\n"
git clone https://bitbucket.org/gameteam360/pylon_ide.git ~/.vim/team_bundle/pylon_ide/
fi
# todo: 更新editorconfig
rm -rf ~/.vim/.editorconfig
if [[ ! -r ~/.editorconfig ]]; then
echo -e "---- 生成 ~/.vim/.editorconfig 文件 ----\n"
cp -f $BASEDIR/.editorconfig ~/
fi