Next: Processor Options, Previous: Starting a Command, Up: Commands [Contents][Index]
Once you started the command selection with C-c C-c, C-c C-s or C-c C-b you will be prompted for the type of command. AUCTeX will try to guess which command is appropriate in the given situation and propose it as default. Usually this is a processor like ‘TeX’ or ‘LaTeX’ if the document was changed or a viewer if the document was just typeset. Other commands can be selected in the minibuffer with completion support by typing TAB.
The available commands are defined by the variable
TeX-command-list
. Per default it includes commands for
typesetting the document (e.g. ‘LaTeX’), for viewing the output
(‘View’), for printing (‘Print’), for generating an index
(‘Index’) or for spell checking (‘Spell’) to name but a few.
You can also add your own commands by adding entries to
TeX-command-list
. Refer to its doc string for information about
its syntax. You might also want to look at TeX-expand-list
to
learn about the expanders you can use in TeX-command-list
.
Note that the default of the variable occasionally changes. Therefore
it is advisable to add to the list rather than overwriting it. You can
do this with a call to add-to-list
in your init file. For
example, if you wanted to add a command for running a program called
‘foo’ on the master or region file, you could do this with the
following form.
(eval-after-load "tex" '(add-to-list 'TeX-command-list '("Foo" "foo %s" TeX-run-command t t :help "Run foo") t))
As mentioned before, AUCTeX will try to guess what command you want
to invoke. If you want to use another command than ‘TeX’,
‘LaTeX’ or whatever processor AUCTeX thinks is appropriate for
the current mode, set the variable TeX-command-default
. You can
do this for all files by setting it in a mode hook or per file by
specifying it as a file variable (see File Variables in The
Emacs Editor).
The default command to run in this buffer. Must be an entry in
TeX-command-list
.
In case you use biblatex in a document, when automatic parsing is
enabled AUCTeX checks the value of ‘backend’ option given to
biblatex at load time to decide whether to use BibTeX or Biber for
bibliography processing. Should AUCTeX fail to detect the right
backend, you can use the file local LaTeX-biblatex-use-Biber
variable.
If this boolean variable is set as file local, it tells to AUCTeX whether to use Biber with biblatex. In this case, the autodetection of the biblatex backend will be overridden. You may want to set locally this variable if automatic parsing is not enabled.
After confirming a command to execute, AUCTeX will try to save any
buffers related to the document, and check if the document needs to be
reformatted. If the variable TeX-save-query
is non-nil,
AUCTeX will query before saving each file. By default AUCTeX will
check emacs buffers associated with files in the current directory, in
one of the TeX-macro-private
directories, and in the
TeX-macro-global
directories. You can change this by setting the
variable TeX-check-path
.
Directory path to search for dependencies.
If nil, just check the current file. Used when checking if any files have changed.
Next: Processor Options, Previous: Starting a Command, Up: Commands [Contents][Index]