Skip to content

Instantly share code, notes, and snippets.

@fsimonis
Created April 19, 2024 11:23
Show Gist options
  • Save fsimonis/70c0f145ed84fa74b8679636a2aeb3e4 to your computer and use it in GitHub Desktop.
Save fsimonis/70c0f145ed84fa74b8679636a2aeb3e4 to your computer and use it in GitHub Desktop.
Latexmkrc quickstart - you won't need more
# Setup directory with extra packages and documentclasses
ensure_path( 'TEXINPUTS', './extra//' );
# Setup out directory
$out_dir = 'build';
# Setup main file
@default_files = ( 'main.tex' );
# Setup command options (use -shell-escape only if necessary)
set_tex_cmds( '-interaction=batchmode -shell-escape -halt-on-error %O %S' );
# Set LaTeX engine to use by default
$pdf_mode = 5; # use xelatex
# Setup extra extensions
push @generated_exts, 'run.xml', 'xdv';
# Use the default application of your linux desktop to preview pdfs
$pdf_previewer = 'start xdg-open %O %S'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment