diff --git a/files/ipa-backup-wrapper.sh b/files/ipa-backup-wrapper.sh index c5434b8..ab76090 100755 --- a/files/ipa-backup-wrapper.sh +++ b/files/ipa-backup-wrapper.sh @@ -1,10 +1,10 @@ #!/bin/sh # -# Script to work around the fact that ipa-backup always adds timestamps to the +# Script to work around the fact that ipa-backup always adds timestamps to the # backups. This is not intended to be used standalone, but from Puppet-managed # cronjobs. # -# NOTE: this script will destroy old timestamped backup directories if timestamp +# NOTE: this script will destroy old timestamped backup directories if timestamp # is set to false. TYPE=$1 @@ -24,7 +24,7 @@ else fi if [ "$TIMESTAMP" = "true" ]; then - # ipa-backup outputs only to stderr so we can't simply redirect to /dev/null + # ipa-backup outputs only to stderr so we can't simply redirect to /dev/null # and expect cron to email us about errors. $BACKUP_COMMAND 2> /dev/null || echo "ERROR: $BACKUP_COMMAND failed!" @@ -36,7 +36,7 @@ elif [ "$TIMESTAMP" = "false" ]; then $BACKUP_COMMAND 2> /dev/null || echo "ERROR: $BACKUP_COMMAND failed!" # Get rid of the timestamp - find $BASEDIR -mindepth 1 -maxdepth 1 -type d -name "ipa-${TYPE}*" -exec mv {} $BASEDIR/ipa-$TYPE \; + find "$BASEDIR" -mindepth 1 -maxdepth 1 -type d -name "ipa-${TYPE}*" -exec mv {} "${BASEDIR}/ipa-${TYPE}" \; else echo "ERROR: $TIMESTAMP is not valid value for timestamp!" exit 1