Variable: TeX-command-list

TeX-command-list is a customizable variable defined in tex.el.

Value

Large value
(("TeX"
  "%(PDF)%(tex) %(file-line-error) %`%(extraopts) %S%(PDFout)%(mode)%' %(output-dir) %t"
  TeX-run-TeX nil (plain-TeX-mode AmSTeX-mode Texinfo-mode) :help
  "Run plain TeX")
 ("LaTeX" "%`%l%(mode)%' %T" TeX-run-TeX nil (LaTeX-mode docTeX-mode)
  :help "Run LaTeX")
 ("Makeinfo" "makeinfo %(extraopts) %(o-dir) %t" TeX-run-compile nil
  (Texinfo-mode) :help "Run Makeinfo with Info output")
 ("Makeinfo HTML" "makeinfo %(extraopts) %(o-dir) --html %t"
  TeX-run-compile nil (Texinfo-mode) :help
  "Run Makeinfo with HTML output")
 ("AmSTeX"
  "amstex %(PDFout) %`%(extraopts) %S%(mode)%' %(output-dir) %t"
  TeX-run-TeX nil (AmSTeX-mode) :help "Run AMSTeX")
 ("ConTeXt" "%(cntxcom) --once %(extraopts) %(execopts)%t" TeX-run-TeX
  nil (ConTeXt-mode) :help "Run ConTeXt once")
 ("ConTeXt Full" "%(cntxcom) %(extraopts) %(execopts)%t" TeX-run-TeX
  nil (ConTeXt-mode) :help "Run ConTeXt until completion")
 ("BibTeX" "%(bibtex) %s" TeX-run-BibTeX nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode
		  ConTeXt-mode)
  :help "Run BibTeX")
 ("Biber" "biber %(output-dir) %s" TeX-run-Biber nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Run Biber")
 ("Texindex" "texindex %s.??" TeX-run-command nil (Texinfo-mode) :help
  "Run Texindex")
 ("Texi2dvi" "%(PDF)texi2dvi %t" TeX-run-command nil (Texinfo-mode)
  :help "Run Texi2dvi or Texi2pdf")
 ("View" "%V" TeX-run-discard-or-function t t :help "Run Viewer")
 ("Print" "%p" TeX-run-command t t :help "Print the file")
 ("Queue" "%q" TeX-run-background nil t :help "View the printer queue"
  :visible TeX-queue-command)
 ("File" "%(o?)dvips %d -o %f " TeX-run-dvips t
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Generate PostScript file")
 ("Dvips" "%(o?)dvips %d -o %f " TeX-run-dvips nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Convert DVI file to PostScript")
 ("Dvipdfmx" "dvipdfmx -o %(O?pdf) %d" TeX-run-dvipdfmx nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Convert DVI file to PDF with dvipdfmx")
 ("Ps2pdf" "ps2pdf %f %(O?pdf)" TeX-run-ps2pdf nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Convert PostScript file to PDF")
 ("LaTeXMk"
  "latexmk %(latexmk-out) %(file-line-error) %(output-dir) %`%(extraopts) %S%(mode)%' %t"
  TeX-run-TeX nil (LaTeX-mode docTeX-mode) :help "Run LaTeXMk")
 ("Glossaries" "makeglossaries %(d-dir) %s" TeX-run-command nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Run makeglossaries to create glossary file")
 ("Index" "%(makeindex) %s" TeX-run-index nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Run makeindex to create index file")
 ("upMendex" "upmendex %(O?idx)" TeX-run-index t
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Run upmendex to create index file")
 ("Xindy" "texindy %s" TeX-run-command nil
  (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
  :help "Run xindy to create index file")
 ("Check" "lacheck %s" TeX-run-compile nil (LaTeX-mode) :help
  "Check LaTeX file for correctness")
 ("ChkTeX" "chktex -v6 %s" TeX-run-compile nil (LaTeX-mode) :help
  "Check LaTeX file for common mistakes")
 ("Spell" "(TeX-ispell-document \"\")" TeX-run-function nil t :help
  "Spell-check the document")
 ("Clean" "TeX-clean" TeX-run-function nil t :help
  "Delete generated intermediate files")
 ("Clean All" "(TeX-clean t)" TeX-run-function nil t :help
  "Delete generated intermediate and output files")
 ("Other" "" TeX-run-command t t :help "Run an arbitrary command"))

Documentation

List of commands to execute on the current document.

Each element is a list, whose first element is the name of the command as it will be presented to the user.

The second element is the string handed to the shell after being expanded. The expansion is done using the information found in TeX-expand-list(var)/TeX-expand-list(fun).

The third element is the function which actually start the process. Several such hooks have been defined:

TeX-run-command: Start up the process and show the output in a separate buffer. Check that there is not two commands running for the same file. Return the process object.

TeX-run-format: As TeX-run-command, but assume the output is created by a TeX macro package. Return the process object.

TeX-run-TeX: For TeX output.

TeX-run-interactive: Run TeX or LaTeX interactively.

TeX-run-BibTeX: For BibTeX output.

TeX-run-Biber: For Biber output.

TeX-run-compile: Use compile to run the process.

TeX-run-shell: Use shell-command to run the process.

TeX-run-discard: Start the process in the background, discarding its output.

TeX-run-background: Start the process in the background, show output in other window.

TeX-run-silent: Start the process in the background.

TeX-run-discard-foreground: Start the process in the foreground, discarding its output.

TeX-run-function: Execute the Lisp function or function call specified by the string in the second element. Consequently, this hook does not start a process.

TeX-run-discard-or-function: If the command is a Lisp function, execute it as such, otherwise start the command as a process, discarding its output.

To create your own hook, define a function taking three arguments: The name of the command, the command string, and the name of the file to process. It might be useful to use TeX-run-command in order to create an asynchronous process.

If the fourth element is non-nil, the user will get a chance to modify the expanded string.

The fifth element indicates in which mode(s) the command should be present in the Command menu. Use t if it should be active in any mode. If it should only be present in some modes, specify a list with the respective mode names.

Any additional elements get just transferred to the respective menu entries.

This variable was added, or its default value changed, in auctex version 14.0.9.

Source Code

;; Defined in ~/.emacs.d/elpa/auctex-14.1.2/tex.el
;; This is the major configuration variable.  Most sites will only need to
;; change the second string in each entry, which is the name of a command to
;; send to the shell.  If you use other formatters like AMSLaTeX or AMSTeX, you
;; can add those to the list.  See `TeX-expand-list' and
;; `TeX-expand-list-builtin' for a description of the % escapes

(defcustom TeX-command-list
  '(("TeX" "%(PDF)%(tex) %(file-line-error) %`%(extraopts) %S%(PDFout)%(mode)%' %(output-dir) %t"
     TeX-run-TeX nil
     (plain-TeX-mode AmSTeX-mode Texinfo-mode) :help "Run plain TeX")
    ("LaTeX" "%`%l%(mode)%' %T"
     TeX-run-TeX nil
     (LaTeX-mode docTeX-mode) :help "Run LaTeX")
    ;; Not part of standard TeX.
    ("Makeinfo" "makeinfo %(extraopts) %(o-dir) %t" TeX-run-compile nil
     (Texinfo-mode) :help "Run Makeinfo with Info output")
    ("Makeinfo HTML" "makeinfo %(extraopts) %(o-dir) --html %t" TeX-run-compile nil
     (Texinfo-mode) :help "Run Makeinfo with HTML output")
    ("AmSTeX" "amstex %(PDFout) %`%(extraopts) %S%(mode)%' %(output-dir) %t"
     TeX-run-TeX nil (AmSTeX-mode) :help "Run AMSTeX")
    ;; support for ConTeXt  --pg
    ;; first version of ConTeXt to support nonstopmode: 2003.2.10
    ("ConTeXt" "%(cntxcom) --once %(extraopts) %(execopts)%t"
     TeX-run-TeX nil (ConTeXt-mode) :help "Run ConTeXt once")
    ("ConTeXt Full" "%(cntxcom) %(extraopts) %(execopts)%t"
     TeX-run-TeX nil
     (ConTeXt-mode) :help "Run ConTeXt until completion")
    ("BibTeX" "bibtex %(O?aux)" TeX-run-BibTeX nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode
                     ConTeXt-mode)
     :help "Run BibTeX")
    ("Biber" "biber %(output-dir) %s" TeX-run-Biber nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Run Biber")
    ;; Not part of standard TeX.
    ;; It seems that texindex doesn't support "--output-dir" option.
    ("Texindex" "texindex %s.??" TeX-run-command nil
     (Texinfo-mode) :help "Run Texindex")
    ;; TODO:
    ;; 1. Supply "--dvipdf" option if `TeX-PDF-mode' and
    ;;    `TeX-PDF-from-DVI' are non-nil.
    ;; 2. Supply "--build-dir=DIR" option when `TeX-output-dir' is
    ;;    non-nil.
    ("Texi2dvi" "%(PDF)texi2dvi %t" TeX-run-command nil
     (Texinfo-mode) :help "Run Texi2dvi or Texi2pdf")
    ("View" "%V" TeX-run-discard-or-function t t :help "Run Viewer")
    ("Print" "%p" TeX-run-command t t :help "Print the file")
    ("Queue" "%q" TeX-run-background nil t :help "View the printer queue"
     :visible TeX-queue-command)
    ("File" "%(o?)dvips %d -o %f " TeX-run-dvips t
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Generate PostScript file")
    ("Dvips" "%(o?)dvips %d -o %f " TeX-run-dvips nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Convert DVI file to PostScript")
    ("Dvipdfmx" "dvipdfmx -o %(O?pdf) %d" TeX-run-dvipdfmx nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Convert DVI file to PDF with dvipdfmx")
    ("Ps2pdf" "ps2pdf %f %(O?pdf)" TeX-run-ps2pdf nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Convert PostScript file to PDF")
    ("LaTeXMk" "latexmk %(latexmk-out) %(file-line-error) %(output-dir) \
%`%(extraopts) %S%(mode)%' %t"
     TeX-run-TeX nil (LaTeX-mode docTeX-mode) :help "Run LaTeXMk")
    ("Glossaries" "makeglossaries %(d-dir) %s" TeX-run-command nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Run makeglossaries to create glossary file")
    ("Index" "makeindex %(O?idx)" TeX-run-index nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Run makeindex to create index file")
    ("upMendex" "upmendex %(O?idx)" TeX-run-index t
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Run upmendex to create index file")
    ("Xindy" "texindy %s" TeX-run-command nil
     (plain-TeX-mode LaTeX-mode docTeX-mode AmSTeX-mode Texinfo-mode)
     :help "Run xindy to create index file")
    ("Check" "lacheck %s" TeX-run-compile nil (LaTeX-mode)
     :help "Check LaTeX file for correctness")
    ("ChkTeX" "chktex -v6 %s" TeX-run-compile nil (LaTeX-mode)
     :help "Check LaTeX file for common mistakes")
    ("Spell" "(TeX-ispell-document \"\")" TeX-run-function nil t
     :help "Spell-check the document")
    ("Clean" "TeX-clean" TeX-run-function nil t
     :help "Delete generated intermediate files")
    ("Clean All" "(TeX-clean t)" TeX-run-function nil t
     :help "Delete generated intermediate and output files")
    ("Other" "" TeX-run-command t t :help "Run an arbitrary command"))
  "List of commands to execute on the current document.

Each element is a list, whose first element is the name of the command
as it will be presented to the user.

The second element is the string handed to the shell after being
expanded.  The expansion is done using the information found in
`TeX-expand-list'.

The third element is the function which actually start the process.
Several such hooks have been defined:

`TeX-run-command': Start up the process and show the output in a
separate buffer.  Check that there is not two commands running for the
same file.  Return the process object.

`TeX-run-format': As `TeX-run-command', but assume the output is created
by a TeX macro package.  Return the process object.

`TeX-run-TeX': For TeX output.

`TeX-run-interactive': Run TeX or LaTeX interactively.

`TeX-run-BibTeX': For BibTeX output.

`TeX-run-Biber': For Biber output.

`TeX-run-compile': Use `compile' to run the process.

`TeX-run-shell': Use `shell-command' to run the process.

`TeX-run-discard': Start the process in the background, discarding its
output.

`TeX-run-background': Start the process in the background, show output
in other window.

`TeX-run-silent': Start the process in the background.

`TeX-run-discard-foreground': Start the process in the foreground,
discarding its output.

`TeX-run-function': Execute the Lisp function or function call
specified by the string in the second element.  Consequently,
this hook does not start a process.

`TeX-run-discard-or-function': If the command is a Lisp function,
execute it as such, otherwise start the command as a process,
discarding its output.

To create your own hook, define a function taking three arguments: The
name of the command, the command string, and the name of the file to
process.  It might be useful to use `TeX-run-command' in order to
create an asynchronous process.

If the fourth element is non-nil, the user will get a chance to
modify the expanded string.

The fifth element indicates in which mode(s) the command should be
present in the Command menu.  Use t if it should be active in any
mode.  If it should only be present in some modes, specify a list with
the respective mode names.

Any additional elements get just transferred to the respective menu entries."
  :group 'TeX-command
  :type '(repeat (group :value ("" "" TeX-run-command nil t)
                        (string :tag "Name")
                        (string :tag "Command")
                        (choice :tag "How"
                                :value TeX-run-command
                                (function-item TeX-run-command)
                                (function-item TeX-run-format)
                                (function-item TeX-run-TeX)
                                (function-item TeX-run-interactive)
                                (function-item TeX-run-BibTeX)
                                (function-item TeX-run-Biber)
                                (function-item TeX-run-compile)
                                (function-item TeX-run-shell)
                                (function-item TeX-run-discard)
                                (function-item TeX-run-background)
                                (function-item TeX-run-silent)
                                (function-item TeX-run-discard-foreground)
                                (function-item TeX-run-function)
                                (function-item TeX-run-discard-or-function)
                                (function :tag "Other"))
                        (boolean :tag "Prompt")
                        (choice :tag "Modes"
                                (const :tag "All" t)
                                (set (const :tag "Plain TeX" plain-TeX-mode)
                                     (const :tag "LaTeX" LaTeX-mode)
                                     (const :tag "DocTeX" docTeX-mode)
                                     (const :tag "ConTeXt" ConTeXt-mode)
                                     (const :tag "Texinfo" Texinfo-mode)
                                     (const :tag "AmSTeX" AmSTeX-mode)))
                        (repeat :tag "Menu elements" :inline t sexp)))
  :package-version '(auctex . "14.0.9"))