From: Ian Jackson Date: Wed, 19 Feb 2020 23:40:03 +0000 (+0000) Subject: quacks-ingredients: gcode manipulation X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=9460393bb7e8d706c9cd2bc61bf0a779d66a0b77;p=reprap-play.git quacks-ingredients: gcode manipulation L234 Signed-off-by: Ian Jackson --- diff --git a/quacks-ingredients-make-copy-gcodes b/quacks-ingredients-make-copy-gcodes index bcddcf7..35b2d84 100755 --- a/quacks-ingredients-make-copy-gcodes +++ b/quacks-ingredients-make-copy-gcodes @@ -39,17 +39,27 @@ for l in 1 2 3 4 5; do ' $g done +exec 3>${lhs}234.auto.gcode +for l in 2 3; do + gh + perl -pe 's/^/;/ if m/^M104 S0\b/ || (m/^M84/..0)' $g >&3 +done +for l in 4; do + gh + cat $g >&3 +done + umount /media/sd >/dev/null 2>&1 ||: mount /media/sd -for l in 1 2 3 4 5; do +for l in 1 2 3 4 5 234; do cp $g $h done umount /media/sd mount /media/sd -for l in 1 2 3 4 5; do +for l in 1 2 3 4 5 234; do gh cmp $g $h ls -l $h