reworked main program
This commit is contained in:
13
init.sh
13
init.sh
@@ -130,7 +130,8 @@ done
|
||||
if [[ $CHECK_ONLY == true ]]; then
|
||||
prnt I "Mode de vérification seulement, on s'arrête là."
|
||||
exit 0
|
||||
else
|
||||
fi
|
||||
|
||||
if [[ $JUMP == true ]]; then
|
||||
prnt W "Les vérification sont évités, attention !"
|
||||
else
|
||||
@@ -143,13 +144,12 @@ else
|
||||
echo -e "${BRed}ATTENTION : Cette option ne devrait être utilisé que sur système de test.${DEFAULTCOL}"
|
||||
echo
|
||||
fi
|
||||
echo "Appuyez sur CTLR + C maintenant si vous souhaitez interrompre."
|
||||
echo -e "${BYellow}Si vous continuez après cette étape le système sera modifié !${DEFAULTCOL}"
|
||||
echo
|
||||
while read -r -t 0.001; do :; done # Dump the buffer
|
||||
read -n 1 -prs $"Appuyer sur n'importe quelle touche pour continuer...\n"
|
||||
fi
|
||||
read -n 1 -rsp $"Appuyer sur la touche <C> pour continuer ou une autre pour s'arrêter...\n" key
|
||||
|
||||
if [[ $key == "C" || $key == 'c' ]]; then
|
||||
# We launch modules one after one
|
||||
for mod in $MODULE_LIST; do
|
||||
if [[ $RESUME == true ]] && [[ $(grep $mod $STAGE_FILE) ]]; then
|
||||
@@ -162,6 +162,11 @@ for mod in $MODULE_LIST; do
|
||||
$mod
|
||||
echo $mod >> $STAGE_FILE # Mark as done for resuming function
|
||||
done
|
||||
echo
|
||||
else
|
||||
echo -e "${Yellow}Le système n'a subit aucune modifications.${DEFAULTCOL}"
|
||||
echo
|
||||
fi
|
||||
|
||||
prnt I "That's all folks !"
|
||||
rm -f $STAGEFILE
|
||||
|
||||
Reference in New Issue
Block a user