diff options
| author | Anton Bobov <abobov@gmail.com> | 2016-01-21 20:11:55 +0500 |
|---|---|---|
| committer | Anton Bobov <abobov@gmail.com> | 2016-01-21 20:13:19 +0500 |
| commit | 9f305e760757633623a59997358e1014d548493f (patch) | |
| tree | 50788480388ad10b39226a79654f3f27dc75cd35 /install.sh | |
| parent | 13594290ac32e0ecbf17a51418268a596a213451 (diff) | |
Fix install script.
Diffstat (limited to 'install.sh')
| -rwxr-xr-x | install.sh | 17 |
1 files changed, 11 insertions, 6 deletions
@@ -37,16 +37,21 @@ create_link() { done } +check_command() { + if ! $(which "$1" >/dev/null 2>&1) ; then + echo "No $1." >&2 + if $(which "command-not-found" >/dev/null 2>&1) ; then + command-not-found "$1" + fi + fi +} + after_install() { mkdir -p $HOME/tmp/vim-undo $HOME/tmp/vim-backup mkdir -p $HOME/.mutt/cache touch $HOME/.mutt/aliases - if ! which ctags >/dev/null 2>&1; then - echo 'No ctags.' >&2 - fi - if ! which ag >/dev/null 2>&1; then - echo 'No ag.' >&2 - fi + check_command ctags + check_command ag } check_override() { |
