#!/bin/bash tmpdir=~/tmp/w file=`basename $1 .txt` dest=`pwd`/results mkdir -p $tmpdir gawk -f scripts/stats.awk -f util.awk -v Col1=$2 -v Col2=$3 < $1 > $tmpdir/$file.tex cd $tmpdir latex $tmpdir/$file.tex dvipdf $tmpdir/$file.dvi mv $tmpdir/$file.pdf $dest mv $tmpdir/$file.tex $dest echo "Results stored at: "$dest/$file".pdf" evince $dest/$file".pdf" &