Rst in peace

Thursday, 15 November 2007

I have taken to use reStructuredText wherever possible. I write software specs, migration docs etc., in rst. The only time when I feel unnatural about rst is when I'm marking up tables. Too many dashes and +s in right places.

Here is a bash script to convert rst files to pdf and view it.

    #! /bin/bash
    bname=`basename $1 .rst`
    rst2latex $1 > /tmp/$bname.tex
    pdflatex /tmp/$bname.tex
    evince $bname.pdf
    echo "$1 converted to $bname.pdf"