
say "Setting up local data for demonstration"
sic mkdir "raw"
sic copy "gag_demo:h2co.lmv" "raw/h2co.lmv"
sic mkdir "tmp"
sic delete "tmp/*"

pause

say ""
say "========= From scratch + direct order ========="
sic delete "tmp/h2co.tuple"
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /ima real
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From scratch + transposed order ========="
sic delete "tmp/h2co.tuple"
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /spe out
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From consistent tuple + direct order ========="
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /ima real
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From consistent tuple + transposed order ========="
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /spe out
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From inconsistent tuple (raw file was changed) + direct order ========="
system "touch raw/h2co.lmv"
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /ima real
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From inconsistent tuple (raw file was changed) + transposed order ========="
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /spe out
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From inconsistent tuple (transposed file was changed) + transposed order ========="
system "touch tmp/h2co-lmv.vlm"
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /spe out
say ""
say "--- Tuple status after command:"
tuple h2co

pause

say ""
say "========= From inconsistent tuple (transposed file was changed) + direct order ========="
say ""
say "--- Tuple status before command:"
tuple h2co
say ""
say "--- Command execution:"
template h2co /ima real
say ""
say "--- Tuple status after command:"
tuple h2co
