Переглянути джерело

added option to continue setup even when a command is missing

master
mort 9 роки тому
джерело
коміт
2e0195aba9
1 змінених файлів з 6 додано та 2 видалено
  1. 6
    2
      setup.sh

+ 6
- 2
setup.sh Переглянути файл

@@ -4,8 +4,12 @@ check_exists()
{
which "$1" 1> /dev/null
if [ "$?" -ne 0 ]; then
echo "Missing command: ${1}. install it."
exit 1
echo "Warning: Missing command: ${1}. Continue? (y/n)"
read response
if [ "$response" != "y" ]; then
echo "Aborting."
exit 1
fi
fi
}


Завантаження…
Відмінити
Зберегти