diff options
| author | Robert Bruce Park <r@robru.ca> | 2013-11-13 09:12:50 -0800 |
|---|---|---|
| committer | Robert Bruce Park <r@robru.ca> | 2013-11-13 09:12:50 -0800 |
| commit | fe0bfde041ded29812a56228f3b4f4c96178462b (patch) | |
| tree | d992435abaf7d457e265a6d7c22f4a440e9ec152 | |
| parent | d425a05528718d4d788ca1bd0d33f1c54d4fedfe (diff) | |
More robust path handling.
| -rw-r--r-- | rsync_tmbackup.sh | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/rsync_tmbackup.sh b/rsync_tmbackup.sh index 100ce9f..a3a42fa 100644 --- a/rsync_tmbackup.sh +++ b/rsync_tmbackup.sh @@ -161,11 +161,11 @@ while [ "1" ]; do elif [ $stamp -ge $KEEP_DAILIES_DATE ]; then # Delete all but the most recent of each day. - [ ${date:8:2} -eq ${prev:8:2} ] && echo rm -rf $DEST_FOLDER/$date + [ ${date:8:2} -eq ${prev:8:2} ] && echo rm -rf -- "$DEST_FOLDER/$date" else # Delete all but the most recent of each month. - [ ${date:5:2} -eq ${prev:5:2} ] && echo rm -rf $DEST_FOLDER/$date + [ ${date:5:2} -eq ${prev:5:2} ] && echo rm -rf -- "$DEST_FOLDER/$date" fi prev=$date |
