Subversion Repositories HelenOS-doc

Rev

Blame | Last modification | View Log | Download | RSS feed

  1. #! /bin/bash
  2.  
  3. RUBBER="`which rubber 2> /dev/null`"
  4. BASENAME="`basename "$1" .tex`"
  5.  
  6. if [ -n "$RUBBER" ] ; then
  7.     "$RUBBER" -fvpd -W all "$1"
  8. else
  9.     for i in `seq 1 3` ; do
  10.         latex -halt-on-error "$1"
  11.     done
  12.     dvips -t letter -o "${BASENAME}.ps" "${BASENAME}.dvi"
  13.     ps2pdf "${BASENAME}.ps" "${BASENAME}.pdf"
  14. fi
  15.  
  16. if [ -e "${BASENAME}.todo" ] ; then
  17.     TODOS="`wc -l "${BASENAME}.todo" | cut -d' ' -f1`"
  18.     if [ "$TODOS" -gt 0 ] ; then
  19.         echo "Warning: $TODOS unresolved TODOs, see ${BASENAME}.todo for details"
  20.     fi
  21. fi
  22.