#! /bin/sh # # draw maze solution # case "$#" in 0) f="solve.out";; *) f="$1";; esac # maze data from stdin, solution data from $f # exec 2>plot.stderr (printf "set term gif\nset output\nunset border\nunset xtics\nunset ytics\n\ plot '-' notitle with lines lc rgb 'black', '$f' notitle with lines lc rgb 'red'"; cat) | gnuplot