Correction test longueur path pour echo de fin de script

This commit is contained in:
John Doe 2022-07-26 23:19:36 +02:00
parent f53a3ccc61
commit 02ace53e42
1 changed files with 6 additions and 5 deletions

View File

@ -144,11 +144,12 @@ if [ "$RUNNING_FROM_CRON" == "0" ]; then
text1="${text1}*"
done
if [ $((2 * $count)) != "50" ]; then
text2="$text1*"
else
text2="$text1"
fi
LONGUEURPATH=$((`expr length $LOG`))
if [ $(($LONGUEURPATH%2)) -eq 0 ]; then #Test si le nombre de caractère du [path + nom fichier] est paire
text2="$text1" #si paire
else
text2="$text1*"
fi
text="$text1 $LOG $text2"
printf '*%.0s' {1..50}; printf '\n'