diff options
author | Karel Kočí <cynerd@email.cz> | 2017-02-25 19:30:37 +0100 |
---|---|---|
committer | Karel Kočí <cynerd@email.cz> | 2017-02-25 19:30:37 +0100 |
commit | e7086db0959d70e51cb04d8821d6b8b13ebf8878 (patch) | |
tree | b7d86e619369d4286ec50c59a8074b3cb84cd373 /install | |
parent | ff931f9bcdfb16ccb9ee0c6aa0085a5688e7d2cc (diff) | |
download | myconfigs-e7086db0959d70e51cb04d8821d6b8b13ebf8878.tar.gz myconfigs-e7086db0959d70e51cb04d8821d6b8b13ebf8878.tar.bz2 myconfigs-e7086db0959d70e51cb04d8821d6b8b13ebf8878.zip |
Update the way git repositories are handled
Diffstat (limited to 'install')
-rwxr-xr-x | install | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -42,15 +42,15 @@ fi read -p "Install VIM scripts? (Y/n) " YCM_PATH=~/.vim/bundle/YouCompleteMe if [[ $REPLY =~ ^[Yy]?$ ]]; then - YCM_REV="$(cd $YCM_PATH && git --work-tree=. rev-parse HEAD)" + # See if we have anything different from what we have in repository + YCM_REV="$(cd $YCM_PATH && git --work-tree=. diff --exit-code -s && echo y)" inst vimrc ~/.vimrc inst vim/ ~/.vim inst local/bin/vim-project-gen ~/.local/bin/vim-project-gen mkdir -p ~/.cache/vim # directory for *.swp files mkdir -p ~/.cache/vim-undo # directory for undo files - # Check if YCM was updated and if so recompile - if [ "$YCM_REV" != "$(cd $YCM_PATH && git --work-tree=. rev-parse HEAD)" ]; then ( - cd ~/.vim/bundle/YouCompleteMe + if [ "$YCM_REV" != "y" ]; then ( + cd $YCM_PATH ./install.py --clang-completer --system-libclang --racer-completer ); else echo "YouCompleteMe is not required to be recompiled" |