This commit is contained in:
Bob Mottram 2017-06-11 20:31:52 +01:00
parent 3b1cc15f4e
commit 617e8f940d
1 changed files with 21 additions and 1 deletions

View File

@ -47,19 +47,39 @@ function please_wait {
echo -n '' echo -n ''
} }
please_wait #please_wait
max_files=0
UTILS_FILES=/usr/share/${PROJECT_NAME}/utils/${PROJECT_NAME}-utils-* UTILS_FILES=/usr/share/${PROJECT_NAME}/utils/${PROJECT_NAME}-utils-*
for f in $UTILS_FILES for f in $UTILS_FILES
do do
max_files=$((max_files + 1))
done
APP_FILES=/usr/share/${PROJECT_NAME}/apps/${PROJECT_NAME}-app-*
for f in $APP_FILES
do
max_files=$((max_files + 1))
done
UTILS_FILES=/usr/share/${PROJECT_NAME}/utils/${PROJECT_NAME}-utils-*
file_ctr=0
echo "0" | dialog --gauge $"Please wait" 7 70 0
for f in $UTILS_FILES
do
echo "$((file_ctr * 100 / max_files))" | dialog --gauge $"Please wait" 7 70 0
source $f source $f
file_ctr=$((file_ctr + 1))
done done
APP_FILES=/usr/share/${PROJECT_NAME}/apps/${PROJECT_NAME}-app-* APP_FILES=/usr/share/${PROJECT_NAME}/apps/${PROJECT_NAME}-app-*
for f in $APP_FILES for f in $APP_FILES
do do
echo "$((file_ctr * 100 / max_files))" | dialog --gauge $"Please wait" 7 70 0
source $f source $f
file_ctr=$((file_ctr + 1))
done done
echo "100" | dialog --gauge $"Please wait" 7 70 0
COMPLETION_FILE=$HOME/${PROJECT_NAME}-completed.txt COMPLETION_FILE=$HOME/${PROJECT_NAME}-completed.txt
SELECTED_USERNAME= SELECTED_USERNAME=