From 9a3f4a38aa638d7699e7f59e0db968682023bdbd Mon Sep 17 00:00:00 2001 From: Aaron Lindsay Date: Fri, 7 Feb 2014 07:37:08 -0500 Subject: [PATCH] Add test.sh script --- test.sh | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 test.sh diff --git a/test.sh b/test.sh new file mode 100755 index 0000000..26d0a72 --- /dev/null +++ b/test.sh @@ -0,0 +1,12 @@ +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 + grep -v "_" test_latest | ./binary_backups.sh -r -d "$backup_date" | xargs -I "{}" sed -ri "s/{}/__________/g" test_latest + mv test_results test_results_old + paste -d " " test_latest test_results_old > test_results +done + +rm test_results_old