aboutsummaryrefslogtreecommitdiff
path: root/mkar
diff options
context:
space:
mode:
authorrodri <rgl@antares-labs.eu>2023-04-04 11:35:46 +0000
committerrodri <rgl@antares-labs.eu>2023-04-04 11:35:46 +0000
commit7e00a60abbc505720a4709e00dc7ebe7b6cb2cfc (patch)
tree8d4b70b09d92f9420e1958e0aa388ba29148575e /mkar
parent6cc9b050543c55f62004d2888513f78ba6683673 (diff)
downloadrcfitness-7e00a60abbc505720a4709e00dc7ebe7b6cb2cfc.tar.gz
rcfitness-7e00a60abbc505720a4709e00dc7ebe7b6cb2cfc.tar.bz2
rcfitness-7e00a60abbc505720a4709e00dc7ebe7b6cb2cfc.zip
added an archival tool. updated the default calisthenics session.
Diffstat (limited to 'mkar')
-rwxr-xr-xmkar15
1 files changed, 15 insertions, 0 deletions
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
+ }