1
0
Fork 0
exponential-backups/test.sh

13 lines
418 B
Bash
Raw Normal View History

2014-02-07 07:37:08 -05:00
rm -f test_latest test_results
touch test_results
for (( ago=100; ago>=0; ago-- )); do
backup_date=$( date -I -d "$ago days ago")
echo $backup_date >> test_latest
2014-02-15 09:42:22 -05:00
grep -v "_" test_latest | ./exponential_backups.sh -r -d "$backup_date" | xargs -I "{}" sed -ri "s/{}/__________/g" test_latest
2014-02-07 07:37:08 -05:00
mv test_results test_results_old
paste -d " " test_latest test_results_old > test_results
done
rm test_results_old