This can be used to motivate and teach Makefiles.
Process one file:
$ cat data/lorem.in | ./count.py | ./plot.py
Process all files:
$ make [-jN]
SRCS = $(wildcard data/*.in)
OBJS = $(patsubst %.in,%.tmp,$(SRCS))
OBJS += $(patsubst %.in,%.out,$(SRCS))
all: $(OBJS)
# otherwise intermediate tmp files would be deleted
.PRECIOUS: %.tmp
%.tmp: %.in
cat $< | ./count.py > $@
%.out: %.tmp
cat $< | ./plot.py > $@