Browse Source

directory creation for vim

master
Dirk Alders 1 year ago
parent
commit
164aac7256
1 changed files with 9 additions and 1 deletions
  1. 9
    1
      add_vim

+ 9
- 1
add_vim View File

2
 #
2
 #
3
 SCRIPTPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
3
 SCRIPTPATH="$( cd -- "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )"
4
 
4
 
5
+
6
+if [[ ! -e ~/.vim ]]; then
7
+    mkdir -v ~/.vim
8
+fi
9
+
10
+if [[ ! -e ~/.cache/vim ]]; then
11
+    mkdir -v ~/.cache/vim
12
+fi
13
+
5
 if [[ (-e ~/.vimrc || -e ~/.vim/skeletons) ]]; then
14
 if [[ (-e ~/.vimrc || -e ~/.vim/skeletons) ]]; then
6
     echo "A vim configuration already exists (~/.vimrc or ~/.vim/skeletons)"
15
     echo "A vim configuration already exists (~/.vimrc or ~/.vim/skeletons)"
7
     echo "Remove this configuration and start the script again"
16
     echo "Remove this configuration and start the script again"
10
     ln -vs $SCRIPTPATH/.vimrc ~/.vimrc
19
     ln -vs $SCRIPTPATH/.vimrc ~/.vimrc
11
     ln -vs $SCRIPTPATH/.vim/skeletons ~/.vim/skeletons
20
     ln -vs $SCRIPTPATH/.vim/skeletons ~/.vim/skeletons
12
 fi
21
 fi
13
-

Loading…
Cancel
Save