0.0
No commit activity in last 3 years
No release in over 3 years
Nanoc filter to convert latex files to pdf using latexmk
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies
 Project Readme

Nanoc-latexmk

Gem Version

Nanoc filter to compile .tex files to pdf using the latexmk command. Supports both pdflatex and xelatex.

System requirements

You need everything to build your LaTeX file manually, so latexmk, pdflatex and xelatex need to be installed on your system.

Installation

To use this filter, add nanoc-latexmk to your Gemfile.

gem 'nanoc-latexmk'

Then require this project in your Rules:

require 'nanoc/latexmk'

Usage

First, be sure to add tex to the text_extensions in your nanoc.yaml.

With a basic file in content/file.tex:

---
title: Hello
---
\section{World}

And a layout in layouts/default.tex.erb

\documentclass{article}
\title{<%= item[:title] %>}
\begin{document}
\maketitle
<%= yield %>
\end{document}

You can add this to your Rules

compile '/**/*.tex', rep: :pdf do
  layout '/default.tex.erb'
  filter :latexmk
  write ext: 'pdf'
end

Results in: Hello World PDF

Licence

See the UNLICENSE for details.

Author

Rien Maertens maertensrien@gmail.com

Changelog

See the CHANGELOG for details.