# always process the following tex files
@default_files = ("thesis.tex");# gen synctex
$latex = "latex -synctex=1 %O %S";# gen .pdf on osx with pstopdf
$pdf_mode = "2";
$ps2pdf = "pstopdf %S -o %D";# open .ps and .pdf with skim
$ps_previewer = "open -a Skim";
$pdf_previewer = "open -a Skim";
Compile and watch
# run latexmk and open skim
latexmk -pvc
# run latexmk and open skim (postscript only)
latexmk -ps -pdf- -pvc