X-Git-Url: https://git.sthu.org/?p=vimconf.git;a=blobdiff_plain;f=install.sh;h=6def7c94c7c5796b69d1cc9e64fe74ccf4820389;hp=3b9cfe762276e31d8ac1742d0ded2c540672f3c4;hb=940c5d4d85492624fab8c01bfd8c98e3eadadc42;hpb=f9aeac9df880d0dfd058b149112ab25d6b2dce5d diff --git a/install.sh b/install.sh index 3b9cfe7..6def7c9 100755 --- a/install.sh +++ b/install.sh @@ -4,6 +4,10 @@ set -e check_vim() { + if /usr/bin/vim --version | grep -q "NVIM"; then + return + fi + if /usr/bin/vim --version | grep -q "$1"; then echo "vim has support for $1." else @@ -25,18 +29,30 @@ check_py3() check_prog() { if which "$1" > /dev/null; then - echo "$1 found" + echo "$1 found." else echo "$1 not found. Aborting." exit fi } +check_font() +{ + if fc-list | grep -q "$1"; then + echo "Font $1 found." + else + echo "Font $1 not found. Either install it or clear g:enable_plugin_devicons." + fi +} + check_requirements() { - check_vim +python3 check_prog aspell + check_prog curl + check_prog git + check_vim +python3 check_py3 neovim + check_font "Hack NF" } backup() {