From 3b1d3b6f5eac2e1279d75de43d5eaca12f7c13b4 Mon Sep 17 00:00:00 2001 From: johannst Date: Sat, 13 Jul 2019 15:09:53 +0200 Subject: added -y flag to install to auto answer yes --- install | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'install') diff --git a/install b/install index fa14673..2b89b5c 100755 --- a/install +++ b/install @@ -255,9 +255,11 @@ function main() { echo -e "\t$conf" done - echo "Install this configs? [yY/nN]" - read go_install - [[ $go_install =~ ^[^yY]$ ]] && exit 0 + [[ $1 != '-y' ]] && { + echo "Install this configs? [yY/nN]" + read go_install + [[ $go_install =~ ^[^yY]$ ]] && exit 0 + } for conf in ${configToInstall[@]}; do installConfig $conf @@ -330,4 +332,4 @@ isInstallerDefined () { #}}} -main +main $1 -- cgit v1.2.3