Action plugins

Action plugins control how files should be compiled.

There is a list of plugins shipped with Évariste, but you can also write your own.

Which plugin applies to which file?

Automatic selection

Each action plugin have a priority and a match() method. By default, the plugin used to compile a file is the plugin with the highest priority that matches the file (i.e. myplugin.match(file) returns True).

Manual selection

However, user can explicitely choose a plugin for a given file, in an evsignore file:

Manual selection of an action plugin
[action]
plugin = foo

[action.foo]
bar = options for plugin foo

Options

Each plugin has its own set of options. However, every action plugin accepts options Targets and Depends.

Targets

Évariste cannot guess the name of the files that will be produced by an action. Use this option to define the targets, i.e. a space separated list of files that are generated by a given action. This option is formatted.

In the following example, the command produces two files: a pdf and a png.

Example of the targets option.
[action.command]
targets = {basename}.pdf {basename}.png
command =
   latex {basename}
   convert {basename}.pdf {basename}.png

Depends

The source files of a compiled one should not appear in the output of Évariste. By default, the file “trigerring” the action is considered the source file, and discarded. But, for instance, if you compile a tex files that includes a png image, you would like both files to be ignored in the final output. To do so, depends option is a space separated list of files that the compiled file depends on, and which should be discarded in the final output.

In the following example, the image.png file will be ignored in the final output.

Example of the depends option.
[action.command]
depends = image.png
targets = {basename}.pdf
command = pdflatex {basename}

Note that the command plugin (and the plugins that inherit from it) accept the experimental, slower strace option, which automatically detects the files that the compiled file depends on.