If your main file is mypaper.tex:
$ curl -O https://raw.githubusercontent.com/ransford/pdflatex-makefile/master/Makefile.include
$ cat > Makefile
TARGET=mypaper
include Makefile.include
Simple Makefile for typesetting papers using pdflatex.
Features:
- Simple to use: just set
TARGET=<yourpaper>andinclude Makefile.include. See theexample/directory for a usage example. - Supports multiple targets: set
TARGETS=paper1 paper2instead ofTARGET. - Calculates dependencies sanely. Detects changes to included .tex and .bib files and rebuilds when appropriate.
- Detects your revision control system (svn, git, hg) and defines a
\Revisioncommand you can use in your LaTeX markup to include a current revision identifier. Useful for circulating drafts for comment. make viewopens your typeset document.- Distills a camera-ready PDF (with fonts embedded):
make distill - To generate a draft with the revision number in its filename (to pass
around), use
make snapshot.