From 7e00a60abbc505720a4709e00dc7ebe7b6cb2cfc Mon Sep 17 00:00:00 2001 From: rodri Date: Tue, 4 Apr 2023 11:35:46 +0000 Subject: added an archival tool. updated the default calisthenics session. --- mkar | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100755 mkar (limited to 'mkar') diff --git a/mkar b/mkar new file mode 100755 index 0000000..abcc41d --- /dev/null +++ b/mkar @@ -0,0 +1,15 @@ +#!/bin/rc +rfork en +wdir=$home/lib/fitness +years=(2020 2021 2022) +months=(jan feb mar apr may jun jul aug sep oct nov dec) + +mkdir -p $wdir/archive + +for(y in $years) + for(m in $months) + if(! ~ `{ls *$m$y >[2]/dev/null | wc -l} 0){ + tar cvzf $m$y.tgz *$m$y + mv $m$y.tgz $wdir/archive/ + rm *$m$y + } -- cgit v1.2.3