node package manager

gulp-pdflatex2

gulp-pdflatex2

npm npm npm GitHub pull requests GitHub issues

GitHub watchers GitHub forks

gulp-pdflatex2 is a wrapper around pdflatex for compiling .tex files into .pdf files. It is an improved version of gulp-pdflatex that displays LaTeX compilation errors instead of suppressing them.

Installation

npm install --save gulp-pdflatex2

Usage

// gulp-rename is not required, but very helpful for redirecting your 
// .tex files to a specific output directory. 
var gulp = require('gulp');
var rename = require('gulp-rename');
var pdflatex2 = require('gulp-pdflatex2');
 
gulp.task('latex', function() {
  return gulp.src('./*.tex')
    .pipe(pdflatex2({
      TEXINPUTS: ['./path/to/cls']
    }))
    .pipe(rename(function(path) {
      path.dirname += '/output';
    }))
    .pipe(gulp.dest('./'));
});

Options

  • TEXINPUTS: optional, pass an array of directories for pdflatex to look in for files, useful if you have external class files.

Author

Libraries.io for GitHub Twitter Follow GitHub followers