From d3eab067141b17775dfa3704b5e97618fec33144 Mon Sep 17 00:00:00 2001 From: Asif Bacchus Date: Tue, 15 Sep 2020 23:11:52 -0600 Subject: [PATCH] remove extraneous linebreaks --- ab-openldap/ab-openldap-update.sh | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/ab-openldap/ab-openldap-update.sh b/ab-openldap/ab-openldap-update.sh index 48101ea..50511d0 100755 --- a/ab-openldap/ab-openldap-update.sh +++ b/ab-openldap/ab-openldap-update.sh @@ -119,7 +119,7 @@ fi set -- dummy $updateFiles shift for file; do - printf "\nchecking '%s' for updates... " "$file" + printf "checking '%s' for updates... " "$file" repoFileChecksum=$( grep "$file" "$checksumFilename" | grep -o '^\S*' ) if [ -f "$file" ]; then localFileChecksum=$( sha256sum "$file" | grep -o '^\S*' ) @@ -127,15 +127,14 @@ for file; do localFileChecksum=0 fi if ! [ "$localFileChecksum" = "$repoFileChecksum" ]; then - printf "%s[AVAILABLE]%s\n" "$yellow" "$norm" + printf "%s[AVAILABLE]%s " "$yellow" "$norm" updatesAvailable=$((updatesAvailable+1)) # download update - printf "Downloading updated '%s'... " "$file" if ! wget --quiet --tries=3 --timeout=10 -O "$file" "$serverPath$file"; then - printf "%s[ERROR]%s\n\n" "$err" "$norm" + printf "%s[ERROR]%s\n" "$err" "$norm" downloadFailed=$((downloadFailed+1)) else - printf "%s[OK] %s" "$ok" "$norm" + printf "%s[DOWNLOADED] %s" "$ok" "$norm" downloadSuccess=$((downloadSuccess+1)) # verify download localFileChecksum=$( sha256sum "$file" | grep -o '^\S*' )