diff options
Diffstat (limited to 'Master/texmf-dist/doc')
-rw-r--r-- | Master/texmf-dist/doc/man/man1/latexmk.1 | 17 | ||||
-rw-r--r-- | Master/texmf-dist/doc/man/man1/latexmk.man1.pdf | bin | 213929 -> 214715 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/support/latexmk/CHANGES | 9 | ||||
-rw-r--r-- | Master/texmf-dist/doc/support/latexmk/INSTALL | 2 | ||||
-rw-r--r-- | Master/texmf-dist/doc/support/latexmk/README | 18 | ||||
-rw-r--r-- | Master/texmf-dist/doc/support/latexmk/latexmk.pdf | bin | 192124 -> 192210 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/support/latexmk/latexmk.txt | 1592 |
7 files changed, 830 insertions, 808 deletions
diff --git a/Master/texmf-dist/doc/man/man1/latexmk.1 b/Master/texmf-dist/doc/man/man1/latexmk.1 index 98264b7aa9f..a1224937092 100644 --- a/Master/texmf-dist/doc/man/man1/latexmk.1 +++ b/Master/texmf-dist/doc/man/man1/latexmk.1 @@ -1,4 +1,4 @@ -.TH LATEXMK 1 "13 September 2020" "" +.TH LATEXMK 1 "29 September 2020" "" .SH NAME latexmk \- generate LaTeX document .SH SYNOPSIS @@ -276,6 +276,11 @@ This property can also be configured by setting the \fI$bibtex_use\fR variable to 1.5 in a configuration file. .TP +.B -bibtexfudge, -bibtexfudge- +Turn on/off the change-directory fudge needed for old versions (pre-2019) +of bibtex. See documentation of \fI$bibtex_fudge\fR for details. + +.TP .B -bm <message> A banner message to print diagonally across each page when converting the dvi file to postscript. The message must be a single argument on @@ -746,6 +751,11 @@ an already-running previewer. Never run bibtex or biber. Equivalent to the \fB-bibtex-\fR option. .TP +.B -nobibtexfudge +Turn off the change-directory fudge needed for old versions (pre-2019) +of bibtex. See documentation of \fI$bibtex_fudge\fR for details. + +.TP .B -norc Turn off the automatic reading of initialization (rc) files. @@ -3868,8 +3878,9 @@ suggestions that contributed to version 3, and Herbert Schulz. e-mail addresses are not written in their standard form to avoid being harvested too easily.) .SH AUTHOR -Current version, by John Collins (username jcc8 at node psu.edu). -(Version 4.70a). +Current version, by John Collins +(Version 4.70b). +Report bugs etc to his e-mail (jcc8 at psu.edu). Released version can be obtained from CTAN: <http://www.ctan.org/pkg/latexmk/>, and from the diff --git a/Master/texmf-dist/doc/man/man1/latexmk.man1.pdf b/Master/texmf-dist/doc/man/man1/latexmk.man1.pdf Binary files differindex 15ba2e728ae..49118f3adec 100644 --- a/Master/texmf-dist/doc/man/man1/latexmk.man1.pdf +++ b/Master/texmf-dist/doc/man/man1/latexmk.man1.pdf diff --git a/Master/texmf-dist/doc/support/latexmk/CHANGES b/Master/texmf-dist/doc/support/latexmk/CHANGES index ac91892ccb9..018ff33c5c4 100644 --- a/Master/texmf-dist/doc/support/latexmk/CHANGES +++ b/Master/texmf-dist/doc/support/latexmk/CHANGES @@ -735,3 +735,12 @@ From v. 4.69a to 4.70a Small bug corrections, and changes to some diagnostic messages. Documentation corrections. +From v. 4.70a to 4.70b + Fix problems when rearranging rules to deal with change of output file of + *latex engine (e.g., .pdf to .dvi). + Fix problem with the new default not to do the change of directory for + bibtex. Use of full path names for output-directory or tex file no + longer causes a bibtex error. + Add options -bibfudge, -bibfudge-, -nobibfudge. + + diff --git a/Master/texmf-dist/doc/support/latexmk/INSTALL b/Master/texmf-dist/doc/support/latexmk/INSTALL index 33acea5cb17..1e1d6d79c2b 100644 --- a/Master/texmf-dist/doc/support/latexmk/INSTALL +++ b/Master/texmf-dist/doc/support/latexmk/INSTALL @@ -1,6 +1,6 @@ INSTALLING latexmk ================== - (Version 4.70a, 13 September 2020) + (Version 4.70b, 29 September 2020) John Collins Physics Department diff --git a/Master/texmf-dist/doc/support/latexmk/README b/Master/texmf-dist/doc/support/latexmk/README index 414814d1835..89124040c5a 100644 --- a/Master/texmf-dist/doc/support/latexmk/README +++ b/Master/texmf-dist/doc/support/latexmk/README @@ -1,4 +1,4 @@ -Latexmk, version 4.70a, 13 September 2020 +Latexmk, version 4.70b, 29 September 2020 ----------------------------------------- Latexmk completely automates the process of generating a LaTeX @@ -87,8 +87,7 @@ NOTES:- John Collins ---------------------------- "latexmk -h" ---------------------------- ------- TO STDOUT from JCC's latexmkrc -Latexmk 4.70a: Automatic LaTeX document generation routine +Latexmk 4.70b: Automatic LaTeX document generation routine Usage: latexmk [latexmk_options] [filename ...] @@ -101,6 +100,8 @@ Usage: latexmk [latexmk_options] [filename ...] -bibtex-cond - use bibtex when needed, but only if the bib file exists -bibtex-cond1 - use bibtex when needed, but only if the bib file exists; on cleanup delete bbl file only if bib file exists + -bibfudge - use change-directory fudge needed for old bibtexs + -bibfudge- - don't use change-directory fudge needed for old bibtexs -bm <message> - Print message across the page when converting to postscript -bi <intensity> - Set contrast or intensity of banner -bs <scale> - Set scale for banner @@ -141,11 +142,11 @@ Usage: latexmk [latexmk_options] [filename ...] -l- - turn off -l -latex=<program> - set program used for latex. (replace '<program>' by the program name) - -latexoption=<option> - add the given option to the (pdf)latex command + -latexoption=<option> - add the given option to the *latex command -logfilewarninglist or -logfilewarnings - give list of warnings after run of (pdf)latex + give list of warnings after run of *latex -logfilewarninglist- or -logfilewarnings- - do not give list of warnings after run of (pdf)latex + do not give list of warnings after run of *latex -lualatex - use lualatex for processing files to pdf and turn dvi/ps modes off -M - Show list of dependent files after processing @@ -158,6 +159,7 @@ Usage: latexmk [latexmk_options] [filename ...] -new-viewer - in -pvc mode, always start a new viewer -new-viewer- - in -pvc mode, start a new viewer only if needed -nobibtex - never use bibtex + -nobibfudge - don't use change-directory fudge needed for old bibtexs -nodependents - Do not show list of dependent files after processing -norc - omit automatic reading of system, user and project rc files -output-directory=dir or -outdir=dir @@ -197,9 +199,9 @@ Usage: latexmk [latexmk_options] [filename ...] -r <file> - Read custom RC file (N.B. This file could override options specified earlier on the command line.) - -recorder - Use -recorder option for (pdf)latex + -recorder - Use -recorder option for *latex (to give list of input and output files) - -recorder- - Do not use -recorder option for (pdf)latex + -recorder- - Do not use -recorder option for *latex -rules - Show list of rules after processing -rules- - Do not show list of rules after processing -showextraoptions - Show other allowed options that are simply passed diff --git a/Master/texmf-dist/doc/support/latexmk/latexmk.pdf b/Master/texmf-dist/doc/support/latexmk/latexmk.pdf Binary files differindex 8d7107f7a2a..c7bfe298673 100644 --- a/Master/texmf-dist/doc/support/latexmk/latexmk.pdf +++ b/Master/texmf-dist/doc/support/latexmk/latexmk.pdf diff --git a/Master/texmf-dist/doc/support/latexmk/latexmk.txt b/Master/texmf-dist/doc/support/latexmk/latexmk.txt index cb25edab853..ee48cdb3d1c 100644 --- a/Master/texmf-dist/doc/support/latexmk/latexmk.txt +++ b/Master/texmf-dist/doc/support/latexmk/latexmk.txt @@ -61,7 +61,7 @@ DESCRIPTION - 13 September 2020 1 + 29 September 2020 1 @@ -127,7 +127,7 @@ LATEXMK OPTIONS AND ARGUMENTS ON COMMAND LINE - 13 September 2020 2 + 29 September 2020 2 @@ -193,7 +193,7 @@ LATEXMK(1) General Commands Manual LATEXMK(1) - 13 September 2020 3 + 29 September 2020 3 @@ -259,7 +259,7 @@ LATEXMK(1) General Commands Manual LATEXMK(1) - 13 September 2020 4 + 29 September 2020 4 @@ -312,26 +312,32 @@ LATEXMK(1) General Commands Manual LATEXMK(1) variable to 1.5 in a configuration file. + -bibtexfudge, -bibtexfudge- + Turn on/off the change-directory fudge needed for old versions + (pre-2019) of bibtex. See documentation of $bibtex_fudge for + details. + + -bm <message> A banner message to print diagonally across each page when con- verting the dvi file to postscript. The message must be a sin- - gle argument on the command line so be careful with quoting spa- - ces and such. + gle argument on the command line so be careful with quoting - Note that if the -bm option is specified, the -ps option is as- - sumed. + 29 September 2020 5 - 13 September 2020 5 +LATEXMK(1) General Commands Manual LATEXMK(1) + spaces and such. -LATEXMK(1) General Commands Manual LATEXMK(1) + Note that if the -bm option is specified, the -ps option is as- + sumed. -bi <intensity> @@ -383,15 +389,9 @@ LATEXMK(1) General Commands Manual LATEXMK(1) deleted. - -C Clean up (remove) all regeneratable files generated by latex and - bibtex or biber. This is the same as the -c option with the ad- - dition of dvi, postscript and pdf files, and those specified in - the $clean_full_ext configuration variable. - - - 13 September 2020 6 + 29 September 2020 6 @@ -400,6 +400,11 @@ LATEXMK(1) General Commands Manual LATEXMK(1) LATEXMK(1) General Commands Manual LATEXMK(1) + -C Clean up (remove) all regeneratable files generated by latex and + bibtex or biber. This is the same as the -c option with the ad- + dition of dvi, postscript and pdf files, and those specified in + the $clean_full_ext configuration variable. + This cleanup is instead of a regular make. See the -gg option if you want to do a cleanup than a make. @@ -449,15 +454,10 @@ LATEXMK(1) General Commands Manual LATEXMK(1) tion, before doing the other actions requested. - -d Set draft mode. This prints the banner message "DRAFT" across - your page when converting the dvi file to postscript. Size and - intensity can be modified with the -bs and -bi options. The -bm - option will override this option as this is really just a short - way of specifying: - 13 September 2020 7 + 29 September 2020 7 @@ -466,6 +466,12 @@ LATEXMK(1) General Commands Manual LATEXMK(1) LATEXMK(1) General Commands Manual LATEXMK(1) + -d Set draft mode. This prints the banner message "DRAFT" across + your page when converting the dvi file to postscript. Size and + intensity can be modified with the -bs and -bi options. The -bm + option will override this option as this is really just a short + way of specifying: + latexmk -bm DRAFT Note that if the -d option is specified, the -ps option is as- @@ -513,17 +519,11 @@ LATEXMK(1) General Commands Manual LATEXMK(1) pendent files after processing. - -dF Dvi file filtering. The argument to this option is a filter - which will generate a filtered dvi file with the extension - ".dviF". All extra processing (e.g. conversion to postscript, - preview, printing) will then be performed on this filtered dvi - file. + -dF - Example usage: To use dviselect to select only the even pages of - - 13 September 2020 8 + 29 September 2020 8 @@ -532,6 +532,13 @@ LATEXMK(1) General Commands Manual LATEXMK(1) LATEXMK(1) General Commands Manual LATEXMK(1) + Dvi file filtering. The argument to this option is a filter + which will generate a filtered dvi file with the extension + ".dviF". All extra processing (e.g. conversion to postscript, + preview, printing) will then be performed on this filtered dvi + file. + + Example usage: To use dviselect to select only the even pages of the dvi file: latexmk -dF "dviselect even" foo.tex @@ -579,24 +586,24 @@ LATEXMK(1) General Commands Manual LATEXMK(1) cial. (In this example, the q/.../ construct is a Perl idiom equivalent to using single quotes. This avoids the complica- tions of getting a quote character inside an already quoted - string in a way that is independent of both the shell and the - operating-system.) - The above command line will NOT work under MS-Windows with - cmd.exe or command.com or 4nt.exe. For MS-Windows with these - command shells you could use + 29 September 2020 9 - 13 September 2020 9 +LATEXMK(1) General Commands Manual LATEXMK(1) -LATEXMK(1) General Commands Manual LATEXMK(1) + string in a way that is independent of both the shell and the + operating-system.) + The above command line will NOT work under MS-Windows with + cmd.exe or command.com or 4nt.exe. For MS-Windows with these + command shells you could use latexmk -e "$latex=q/latex %O -shell-escape %S/" file.tex @@ -645,25 +652,25 @@ LATEXMK(1) General Commands Manual LATEXMK(1) -C had been given, and then do a regular make. - -h, -help - Print help information. - -jobname=STRING - Set the basename of output files(s) to STRING, instead of the - default, which is the basename of the specified TeX file. (At + 29 September 2020 10 - 13 September 2020 10 +LATEXMK(1) General Commands Manual LATEXMK(1) -LATEXMK(1) General Commands Manual LATEXMK(1) + -h, -help + Print help information. + -jobname=STRING + Set the basename of output files(s) to STRING, instead of the + default, which is the basename of the specified TeX file. (At present, STRING should not contain spaces.) This is like the same option for current implementations of the @@ -712,23 +719,23 @@ LATEXMK(1) General Commands Manual LATEXMK(1) -latex="COMMAND" option. - -latex="COMMAND" - This sets the string specifying the command to run latex, and is - typically used to add desired options. Since the string nor- - mally contains spaces, it should be quoted, e.g., - latexmk -latex="latex --shell-escape %O %S" foo.tex + 29 September 2020 11 - 13 September 2020 11 +LATEXMK(1) General Commands Manual LATEXMK(1) -LATEXMK(1) General Commands Manual LATEXMK(1) + -latex="COMMAND" + This sets the string specifying the command to run latex, and is + typically used to add desired options. Since the string nor- + mally contains spaces, it should be quoted, e.g., + latexmk -latex="latex --shell-escape %O %S" foo.tex The specification of the contents of the string are the same as for the $latex configuration variable. Depending on your oper- @@ -776,24 +783,25 @@ LATEXMK(1) General Commands Manual LATEXMK(1) -lualatex="COMMAND" This sets the string specifying the command to run lualatex. It - behaves like the -pdflatex option, but sets the variable $luala- - tex. + behaves like the -pdflatex option, but sets the variable - Note: This option when provided with the COMMAND argument only - sets the command for invoking lualatex; it does not turn on the - use of lualatex. That is done by other options or in an initial- - ization file. + 29 September 2020 12 - 13 September 2020 12 +LATEXMK(1) General Commands Manual LATEXMK(1) -LATEXMK(1) General Commands Manual LATEXMK(1) + $lualatex. + + Note: This option when provided with the COMMAND argument only + sets the command for invoking lualatex; it does not turn on the + use of lualatex. That is done by other options or in an initial- + ization file. -M Show list of dependent files after processing. This is equiva- @@ -842,26 +850,26 @@ LATEXMK(1) General Commands Manual LATEXMK(1) view the generated file. By default, latexmk will, in continu- ous-preview mode, test for a previously running previewer for the same file and not start a new one if a previous previewer is - running. However, its test sometimes fails (notably if there is - an already-running previewer that is viewing a file of the same - name as the current file, but in a different directory). This - option turns off the default behavior. - -new-viewer- - The inverse of the -new-viewer option. It puts latexmk in its + 29 September 2020 13 - 13 September 2020 13 +LATEXMK(1) General Commands Manual LATEXMK(1) -LATEXMK(1) General Commands Manual LATEXMK(1) + running. However, its test sometimes fails (notably if there is + an already-running previewer that is viewing a file of the same + name as the current file, but in a different directory). This + option turns off the default behavior. + -new-viewer- + The inverse of the -new-viewer option. It puts latexmk in its normal behavior that in preview-continuous mode it checks for an already-running previewer. @@ -870,6 +878,12 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Never run bibtex or biber. Equivalent to the -bibtex- option. + -nobibtexfudge + Turn off the change-directory fudge needed for old versions + (pre-2019) of bibtex. See documentation of $bibtex_fudge for + details. + + -norc Turn off the automatic reading of initialization (rc) files. N.B. Normally the initialization files are read and obeyed, and @@ -902,6 +916,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) to be printed, and you can configure this in a start up file (by setting the $print_type variable). + + + + 29 September 2020 14 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + However, printing is enabled by default only under UNIX/Linux systems, where the default is to use the lpr command and only on postscript files. In general, the correct behavior for printing @@ -916,18 +942,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) turns them off. - - - - 13 September 2020 14 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - -pdf Generate pdf version of document using pdflatex. (If you wish to use lualatex or xelatex, you can use whichever of the options -pdflua, -pdfxe, -lualatex or -xelatex applies.) To configure @@ -969,6 +983,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) overridden if some other option requires the generation of a pdf file.) + + + 29 September 2020 15 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + If after all options have been processed, pdf generation is still turned off, then generation of a dvi file will be turned on, and then the program used to compiled a document will be la- @@ -984,16 +1009,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) the -pdflatex="COMMAND" option. - - 13 September 2020 15 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - -pdflatex="COMMAND" This sets the string specifying the command to run pdflatex, and is typically used to add desired options. Since the string nor- @@ -1032,33 +1047,33 @@ LATEXMK(1) General Commands Manual LATEXMK(1) be executed before inputting source file. This only works if the command for invoking the relevant *latex is suitably config- ured. See the documentation of the variable $pre_tex_code, and - the substitution strings %P and %U for more details. This op- - tion works by setting the variable $pre_tex_code. + the substitution strings %P and %U for more details. This - See also the -usepretex option. - An example: - latexmk -pretex='\AtBeginDocument{Message\par}' -usepretex - foo.tex + 29 September 2020 16 - But this is better written - latexmk -usepretex='\AtBeginDocument{Message\par}' foo.tex - If you already have a suitable command configured, you only need +LATEXMK(1) General Commands Manual LATEXMK(1) - 13 September 2020 16 + option works by setting the variable $pre_tex_code. + See also the -usepretex option. + An example: + latexmk -pretex='\AtBeginDocument{Message\par}' -usepretex + foo.tex + But this is better written -LATEXMK(1) General Commands Manual LATEXMK(1) + latexmk -usepretex='\AtBeginDocument{Message\par}' foo.tex + If you already have a suitable command configured, you only need latexmk -pretex='\AtBeginDocument{Message\par}' foo.tex @@ -1100,6 +1115,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) version of perl and the operating system on your computer. + + + 29 September 2020 17 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + -pv Run file previewer. If the -view option is used, this will se- lect the kind of file to be previewed (.dvi, .ps or .pdf). Oth- erwise the viewer views the "highest" kind of file selected, by @@ -1114,18 +1140,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) -pvc Run a file previewer and continually update the .dvi, .ps, and/or .pdf files whenever changes are made to source files (see - - - - 13 September 2020 17 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - the Description above). Which of these files is generated and which is viewed is governed by the other options, and is the same as for the -pv option. The preview-continuous option -pvc @@ -1167,6 +1181,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) -pvc- Turn off -pvc. + + + 29 September 2020 18 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + -pvctimeout Do timeout in pvc mode after period of inactivity, which is 30 min. by default. Inactivity means a period when latexmk has de- @@ -1182,16 +1207,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Set period of inactivity in minutes for pvc timeout. - - 13 September 2020 18 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - -quiet Same as -silent @@ -1232,32 +1247,31 @@ LATEXMK(1) General Commands Manual LATEXMK(1) configuration variable. - -recorder- - Do not supply the -recorder option with *latex. - - -rules Show a list of latemk's rules and dependencies after processing. + 29 September 2020 19 - -rules- - Do not show a list of latexmk's rules and dependencies after - processing. (This is the default.) - -showextraoptions - Show the list of extra *latex options that latexmk recognizes, +LATEXMK(1) General Commands Manual LATEXMK(1) - 13 September 2020 19 + -recorder- + Do not supply the -recorder option with *latex. + -rules Show a list of latemk's rules and dependencies after processing. -LATEXMK(1) General Commands Manual LATEXMK(1) + -rules- + Do not show a list of latexmk's rules and dependencies after + processing. (This is the default.) + -showextraoptions + Show the list of extra *latex options that latexmk recognizes, but that it simply passes through to the programs *latex when they are run. These options are (currently) a combination of those allowed by the TeXLive and MiKTeX implementations. (If a @@ -1298,6 +1312,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) itself generates. To change the options used to make the commands run silently, + + + + 29 September 2020 20 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + you need to configure latexmk with changed values of its config- uration variables, the relevant ones being $bib- tex_silent_switch, $biber_silent_switch, $dvipdf_silent_switch, @@ -1312,18 +1338,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The result is that $latex = 'latex %O %S', and similarly for $pdflatex, $lualatex, and $xelatex. (The option -no-pdf needed - - - - 13 September 2020 20 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - for $xelatex is provided automatically, given that %O appears in the definition.) @@ -1364,30 +1378,31 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Sets the command lines for latex, etc, so that they use the code that is defined by the variable $pre_tex_code or that is set by the option -pretex=CODE to execute the specified TeX code before - the source file is read. This option overrides any previous - definition of the command lines. - The result is that $latex = 'latex %O %P', and similarly for - $pdflatex, $lualatex, and $xelatex. (The option -no-pdf needed - for $xelatex is provided automatically, given that %O appears in - the definition.) - -usepretex=CODE - Equivalent to -pretex=CODE -usepretex. Example + 29 September 2020 21 - latexmk -usepretex='\AtBeginDocument{Message\par}' foo.tex - 13 September 2020 21 +LATEXMK(1) General Commands Manual LATEXMK(1) + the source file is read. This option overrides any previous + definition of the command lines. + The result is that $latex = 'latex %O %P', and similarly for + $pdflatex, $lualatex, and $xelatex. (The option -no-pdf needed + for $xelatex is provided automatically, given that %O appears in + the definition.) -LATEXMK(1) General Commands Manual LATEXMK(1) + -usepretex=CODE + Equivalent to -pretex=CODE -usepretex. Example + + latexmk -usepretex='\AtBeginDocument{Message\par}' foo.tex -v, -version @@ -1430,6 +1445,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) This option is equivalent to using the following set of options + + + 29 September 2020 22 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + -pdfxe -dvi- -ps- [Note: Note that the method of implementation of this option, @@ -1445,17 +1471,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) This sets the string specifying the command to run xelatex. It sets the variable $xelatex. - - - 13 September 2020 22 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - Warning: It is important to ensure that the -no-pdf is used when xelatex is invoked, since latexmk expects xelatex to produce an .xdv file, not a .pdf file. If you provide %O in the command @@ -1495,38 +1510,38 @@ EXAMPLES file thesis.tex and any files it uses. After any changes rerun latex the appropriate number of times and - remake the postscript file. If latex - encounters an error, latexmk will - keep running, watching for - source file changes. - % latexmk -c # remove .aux, .log, .bbl, .blg, .dvi, - .pdf, .ps & .bbl files + 29 September 2020 23 -DEALING WITH ERRORS, PROBLEMS, ETC - Some possibilities: - a. If you get a strange error, do look carefully at the output that is - on the screen and in log files. While there is much that is - 13 September 2020 23 +LATEXMK(1) General Commands Manual LATEXMK(1) + remake the postscript file. If latex + encounters an error, latexmk will + keep running, watching for + source file changes. + % latexmk -c # remove .aux, .log, .bbl, .blg, .dvi, + .pdf, .ps & .bbl files -LATEXMK(1) General Commands Manual LATEXMK(1) +DEALING WITH ERRORS, PROBLEMS, ETC + Some possibilities: - notoriously verbose in the output of latex (and that is added to by la- - texmk), the verbosity is there for a reason: to enable the user to di- - agnose problems. Latexmk does repeat some messages at the end of a run - that it thinks would otherwise be easy to miss in the middle of other - output. + a. If you get a strange error, do look carefully at the output that is + on the screen and in log files. While there is much that is notori- + ously verbose in the output of latex (and that is added to by latexmk), + the verbosity is there for a reason: to enable the user to diagnose + problems. Latexmk does repeat some messages at the end of a run that + it thinks would otherwise be easy to miss in the middle of other out- + put. b. Generally, remember that latexmk does its work by running other pro- grams. Your first priority in dealing with errors should be to examine @@ -1562,6 +1577,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) the change.) One solution is just to put the following somewhere in the LaTeX part of the document: + + + 29 September 2020 24 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + \typeout{(bar.baz)} This puts a line in the log file that latexmk will treat as implying @@ -1577,17 +1603,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) i. Ask a question at tex.stackexchange.com. - - - 13 September 2020 24 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - j. Or ask me (the author of latexmk). My e-mail is at the end of this documentation. @@ -1627,6 +1642,18 @@ ALLOWING FOR CHANGE OF OUTPUT FILE TYPE put=0 in the preamble of the document. Another example is where the document uses graphics file of the .pdf, + + + + 29 September 2020 25 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + .jpg, and png types. With the default setting for the graphicx pack- age, these can be processed in compilation to .pdf but not with compi- lation to .dvi. In this case, it is useful to insert \pdfoutput=1 in @@ -1642,18 +1669,6 @@ ALLOWING FOR CHANGE OF OUTPUT FILE TYPE to a non-zero value as it is by default. If this variable is zero, a mismatch of filetypes in the compilation results in an erro. - - - - 13 September 2020 25 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - The second condition for latexmk to be able to handle a change of out- put type is that no explicit requests for .dvi or .ps output files are made. Explicit requests are by the -dvi and -ps, -print=dvi, @@ -1693,6 +1708,18 @@ CONFIGURATION/INITIALIZATION (RC) FILES "/usr/local/share/latexmk/LatexMk", "/usr/local/lib/latexmk/LatexMk". On a MS-Windows system it looks for "C:\latexmk\LatexMk". + + + + 29 September 2020 26 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + On a cygwin system (i.e., a MS-Windows system in which Perl is that of cygwin), latexmk reads the first it finds of "/cygdrive/c/latexmk/LatexMk", @@ -1708,18 +1735,6 @@ CONFIGURATION/INITIALIZATION (RC) FILES 2) The user's RC file, if it exists. This can be in one of two places. The traditional one is ".latexmkrc" in the user's home directory. The - - - - 13 September 2020 26 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - other possibility is "latexmk/latexmkrc" in the user's XDG configura- tion home directory. The actual file read is the first of "$XDG_CON- FIG_HOME/latexmk/latexmkrc" or "$HOME/.latexmkrc" which exists. (See @@ -1760,6 +1775,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) later options on the command line. There is also the -e option, which allows initialization code to be specified in latexmk's command line. + + + 29 September 2020 27 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + For possible examples of code for in an RC file, see the directory ex- ample_rcfiles in the distribution of latexmk (e.g., at http://mir- ror.ctan.org/support/latexmk/example_rcfiles). @@ -1774,18 +1800,6 @@ HOW TO SET VARIABLES IN INITIALIZATION FILES $bibtex = 'bibtex %O %S'; - - - - 13 September 2020 27 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - for the setting of a string variable, $preview_mode = 1; @@ -1826,31 +1840,31 @@ FORMAT OF COMMAND SPECIFICATIONS Placeholders: Supposed you wanted latexmk to use the command elatex in place of the regular latex command, and suppose moreover that you wanted to give it the option "--shell-escape". You could do this by - the following setting: - $latex = 'elatex --shell-escape %O %S'; - The two items starting with the % character are placeholders. These - are substituted by appropriate values before the command is run. Thus - %S will be replaced by the source file that elatex will be applied to, - and %O will be replaced by any options that latexmk has decided to use - for this command. (E.g., if you used the -silent option in the invoca- - tion of latexmk, it results in the replacement of %O by "-interac- - tion=batchmode".) - The available placeholders are: + 29 September 2020 28 - 13 September 2020 28 +LATEXMK(1) General Commands Manual LATEXMK(1) + the following setting: + $latex = 'elatex --shell-escape %O %S'; -LATEXMK(1) General Commands Manual LATEXMK(1) + The two items starting with the % character are placeholders. These + are substituted by appropriate values before the command is run. Thus + %S will be replaced by the source file that elatex will be applied to, + and %O will be replaced by any options that latexmk has decided to use + for this command. (E.g., if you used the -silent option in the invoca- + tion of latexmk, it results in the replacement of %O by "-interac- + tion=batchmode".) + The available placeholders are: %A basename of the main tex file. Unlike %R, this is unaffected by the setting of a jobname by the -jobname option or the $jobname @@ -1892,6 +1906,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) %Y Name of directory for auxiliary output files (see the configura- tion variable $aux_dir). A directory separation character ('/') + + + + 29 September 2020 29 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + is appended if $aux_dir is non-empty and does not end in a suit- able character, with suitable characters being those appropriate to UNIX and MS-Windows, i.e., ':', '/' and '\'. Note that if @@ -1906,18 +1932,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) UNIX and MS-Windows, i.e., ':', '/' and '\'. If for some reason you need a literal % character in your string not - - - - 13 September 2020 29 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - subject to the above rules, use "%%". Appropriate quoting will be applied to the filename substitutions, so @@ -1958,6 +1972,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) string, that is equivalent to having just one. (4) Under cygwin, some complications happen, since cygwin amounts to a complicated merging of UNIX and MS-Windows. See the source code for how I've handled the + + + + 29 September 2020 30 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + problem. Command names containing spaces: Under MS-Windows it is common that the @@ -1973,17 +1999,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) traPDF.exe" %O %S'; - - - 13 September 2020 30 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - (Note about the above example: Under MS-Windows forward slashes are equivalent to backslashes in a filename under almost all circumstances, provided that the filename is inside double quotes. It is easier to @@ -2023,6 +2038,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Options to commands: Setting the name of a command can be used not only for changing the name of the command called, but also to add options to command. Suppose you want latexmk to use latex with source specials + + + + 29 September 2020 31 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + enabled. Then you might use the following line in an initialization file: @@ -2038,18 +2065,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) return system 'latex', @args; } - - - - 13 September 2020 31 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - For some of the more exotic possibilities that then become available, see the section "ADVANCED CONFIGURATION: Some extra resources and ad- vanced tricks". Also see some of the examples in the directory exam- @@ -2088,34 +2103,34 @@ LATEXMK(1) General Commands Manual LATEXMK(1) LIST OF CONFIGURATION VARIABLES USABLE IN INITIALIZATION FILES - In this section are specified the variables whose values can be ad- - justed to configure latexmk. (See the earlier section "Configura- - tion/Initialization (rc) Files" for the files where the configurations - are done.) + In this section are specified the variables whose values can be - Default values are indicated in brackets. Note that for variables that - are boolean in character, concerning whether latexmk does or does not - behave in a certain way, a non-zero value, normally 1, indicates true, - i.e., the behavior occurs, while a zero value indicates a false value, - i.e., the behavior does not occur. - $allow_switch [1] + 29 September 2020 32 - This controls what happens when the output extension of latex, - pdflatex, lualatex or xelatex differs from what is expected. - 13 September 2020 32 +LATEXMK(1) General Commands Manual LATEXMK(1) + adjusted to configure latexmk. (See the earlier section "Configura- + tion/Initialization (rc) Files" for the files where the configurations + are done.) + Default values are indicated in brackets. Note that for variables that + are boolean in character, concerning whether latexmk does or does not + behave in a certain way, a non-zero value, normally 1, indicates true, + i.e., the behavior occurs, while a zero value indicates a false value, + i.e., the behavior does not occur. -LATEXMK(1) General Commands Manual LATEXMK(1) + $allow_switch [1] + This controls what happens when the output extension of latex, + pdflatex, lualatex or xelatex differs from what is expected. (The possible extensions are .dvi, .pdf, .xdv.) This can happen with the use of the \pdfoutput macro in a document compiled un- der latex or pdflatex, or with the use of the \outputmode macro @@ -2155,6 +2170,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) in the <...> and (...) constructions. Otherwise, only do the analysis when fls file doesn't exist or is out of date. + + + + 29 September 2020 33 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + Under normal circumstances, the data in the fls file is reli- able, and the test of the log file gets lots of false positives; usually $analyze_input_log_always is best set to zero. But the @@ -2172,16 +2199,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) the default is to set $analyze_input_log_always to 1. - - 13 September 2020 33 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $auto_rc_use [1] Whether to automatically read the standard initialization (rc) files, which are the system RC file, the user's RC file, and the @@ -2219,6 +2236,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Note that if $banner is nonzero, the $postscript_mode is assumed and the postscript file is always generated, even if it is newer + + + + 29 September 2020 34 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + than the dvi file. $banner_intensity [0.95] @@ -2236,18 +2265,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) will be printed. Experimentation is necessary to get the right scale for your message, as a rule of thumb the scale should be about equal to 1100 divided by the number of characters in the - - - - 13 September 2020 34 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - message. The Default is just right for 5 character messages. This is equivalent to the -bs option. @@ -2285,6 +2302,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Switch(es) for the biber processing program when silent mode is on. + + + + 29 September 2020 35 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $bibtex ["bibtex %O %S"] The BibTeX processing program. @@ -2301,20 +2330,8 @@ LATEXMK(1) General Commands Manual LATEXMK(1) $bibtex_use [1] Under what conditions to run bibtex or biber. When latexmk dis- covers from the log file that one (or more) bibtex/biber-gener- - ated bibliographies are used, it can run bibtex or biber - - - - 13 September 2020 35 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - - whenever it appears necessary to regenerate the bbl file(s) from + ated bibliographies are used, it can run bibtex or biber when- + ever it appears necessary to regenerate the bbl file(s) from their source bib database file(s). But sometimes, the bib file(s) are not available (e.g., for a document obtained from an external archive), but the bbl files are provided. In that case @@ -2351,6 +2368,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) generated. It will also include files made from these first generation generated files. + + + + 29 September 2020 36 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + This operation is somewhat dangerous, and can have unintended consequences, since the files to be deleted are determined from a file created by *latex, which can contain erroneous informa- @@ -2368,18 +2397,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) specified by the $clean_ext, $clean_full_ext and @generated_exts variables.) - - - - 13 September 2020 36 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - This variable is equivalent to specifying one of the -c or -C options. But there should be no need to set this variable from an RC file. @@ -2417,6 +2434,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) You can arrange to remove both the files and the directory by setting + + + + 29 September 2020 37 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $clean_ext = "pythontex-files-%R pythontex-files-%R"; See also the variable @generated_exts. @@ -2435,17 +2464,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) $compiling_cmd [""], $failure_cmd [""], $warning_cmd [""], $success_cmd [""] - - - 13 September 2020 37 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - These variables specify commands that are executed at certain points of compilations. One motivation for their existance is to allow very useful convenient visual indications of compila- @@ -2482,6 +2500,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) These assume that the program xdotool is installed, that the previewer is using an X-Window system for display, and that the title of the window contains the name of the displayed file, as + + + + 29 September 2020 38 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + it normally does. When the commands are executed, the place- holder string %D is replaced by the name of the destination file, which is the previewed file. The above commands result in @@ -2501,17 +2531,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) be invoked. (See the section "Format of Command Specifications" for how to do this.) - - - 13 September 2020 38 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - Naturally, the above settings that invoke the xdotool program are only applicable when the X-Window system is used for the relevant window(s). For other cases, you will have to find what @@ -2547,6 +2566,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) specified on the latexmk command line. 2. Wildcards are allowed in @default_excluded_files. + + + + 29 September 2020 39 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + @default_files [("*.tex")] Default list of files to be processed. @@ -2566,18 +2597,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) @default_files = ("paper_current"); - - - - 13 September 2020 39 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - @default_files = ("paper1", "paper2.tex"); @default_files = ("*.tex", "*.dtx"); @@ -2614,6 +2633,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) *latex programs. This variable is set by the -cd and -cd- op- tions on latexmk's command line. + + + 29 September 2020 40 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $dvi_filter [empty] The dvi file filter to be run on the newly produced dvi file be- fore other processing. Equivalent to specifying the -dF option. @@ -2632,18 +2662,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The command to invoke a dvi-previewer. [Under MS-Windows the default is "start"; then latexmk arranges to use the MS-Windows start program, which will cause to be run whatever command the - - - - 13 September 2020 40 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - system has associated with .dvi files.] Important note: Normally you will want to have a previewer run @@ -2680,6 +2698,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) N.B. The standard dvipdf program runs silently, so adding the silent switch has no effect, but is actually innocuous. But if an alternative program is used, e.g., dvipdfmx, then the silent + + + + 29 September 2020 41 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + switch has an effect. The default setting is correct for dvipdfm and dvipdfmx. @@ -2697,19 +2727,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Switch(es) for dvips program when pdf file is to be generated from .ps file. - - - - - 13 September 2020 41 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $dvips_silent_switch ["-q"] Switch(es) for dvips program when silent mode is on. @@ -2748,6 +2765,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) $failure_cmd [undefined] See the documentation for $compiling_cmd. + + + 29 September 2020 42 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $fdb_ext ["fdb_latexmk"] The extension of the file which latexmk generates to contain a database of information on source files. You will not normally @@ -2764,18 +2792,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) planation. In almost all situations, latexmk does not need to use the time - - - - 13 September 2020 42 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - stamps of the files it works with. However, there are a couple of situations when it needs to know whether a certain file was created in the current run of a program (e.g., *latex) or is a @@ -2814,6 +2830,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) it normally indicates that at least one of the systems is mis- configured. The variable $filetime_offset_report_threshold specifies the smallest size of the difference (or offset) in + + + + 29 September 2020 43 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + seconds between the times of the local and remote system beyond which the offset is reported. This is reported at the point in the latexmk's progress that it measures the offset. The report @@ -2831,17 +2859,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) during a LaTeX run and that are read in by LaTeX in later runs, either directly or indirectly. - - - 13 September 2020 43 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - This list specifies files known to be generated by *latex. It is used in two ways: (a) The specified files are deleted in a cleanup operation (with the -c, -C, -CA, -g and -gg options), @@ -2879,6 +2896,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The general rule latexmk uses for determining when an extra run of some program is needed is that one of the source files has changed. But consider for example a latex package that causes + + + + 29 September 2020 44 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + an encapsulated postscript file (an "eps" file) to be made that is to be read in on the next run. The file contains a comment line giving its creation date and time. On the next run the @@ -2895,24 +2924,12 @@ LATEXMK(1) General Commands Manual LATEXMK(1) This creates a rule for files with extension .eps about lines to ignore. The left-hand side is a Perl idiom for setting an item in a hash. Note that the file extension is specified without a - period. The value, on the right-hand side, is a string - - - - 13 September 2020 44 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - - containing a regular expresssion. (See documentation on Perl - for how they are to be specified in general.) This particular - regular expression specifies that lines beginning with "%%Cre- - ationDate: " are to be ignored in deciding whether a file of the - given extension .eps has changed. + period. The value, on the right-hand side, is a string contain- + ing a regular expresssion. (See documentation on Perl for how + they are to be specified in general.) This particular regular + expression specifies that lines beginning with "%%CreationDate: + " are to be ignored in deciding whether a file of the given ex- + tension .eps has changed. There is only one regular expression available for each exten- sion. If you need more one pattern to specify lines to ignore, @@ -2944,8 +2961,20 @@ LATEXMK(1) General Commands Manual LATEXMK(1) not contain spaces.) The placeholder '%A' is permitted. This will be substituted by - the basename of the TeX file. The primary purpose is when a va- - riety of tex files are to be processed, and you want to use a + the basename of the TeX file. The primary purpose is when a + + + + 29 September 2020 45 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + + variety of tex files are to be processed, and you want to use a different jobname for each but one that is distinct for each. Thus if you wanted to compare compilations of a set of files on different operating systems, with distinct filenames for all the @@ -2962,18 +2991,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) latexmk -pdf *.tex both files will be compiled. The .aux, .log, and .pdf files - - - - 13 September 2020 45 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - will have basenames test1-MSWin32 ante test2-MSWin32 on a MS- Windows system, test1-darwin and test2-darwin on an OS-X system, and a variety of similar cases on linux systems. @@ -3012,6 +3029,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) visible in latexmk's screen output about invocations of kpse- which. + + + 29 September 2020 46 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $landscape_mode [0] If nonzero, run in landscape mode, using the landscape mode pre- viewers and dvi to postscript converters. Equivalent to the -l @@ -3029,17 +3057,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) tex, and $xelatex, see the section "Advanced Configuration". - - - 13 September 2020 46 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - %latex_input_extensions This variable specifies the extensions tried by latexmk when it finds that a LaTeX run resulted in an error that a file has not @@ -3077,6 +3094,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Switch(es) for the LaTeX processing program when silent mode is on. + + + + 29 September 2020 47 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + If you use MikTeX, you may prefer the results if you configure the options to include -c-style-errors, e.g., by the following line in an initialization file @@ -3095,17 +3124,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) $lpr = '"c:/Program Files/Ghostgum/gsview/gsview32.exe" /p'; - - - 13 September 2020 47 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - If gsview is installed in a different directory, you will need to make the appropriate change. Note the combination of single and double quotes around the name. The single quotes specify @@ -3141,6 +3159,19 @@ LATEXMK(1) General Commands Manual LATEXMK(1) tex, and $xelatex, see the section "Advanced Configuration". + + + + + 29 September 2020 48 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + %lualatex_input_extensions This variable specifies the extensions tried by latexmk when it finds that a lualatex run resulted in an error that a file has @@ -3161,17 +3192,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Switch(es) for the lualatex program (specified in the variable $lualatex) when silent mode is on. - - - 13 September 2020 48 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - See details of the $latex_silent_switch for other information that equally applies to $lualatex_silent_switch. @@ -3206,6 +3226,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) For almost all programs and for almost all filenames under MS- Windows, both "\" and "/" are acceptable as the directory sepa- rator character, provided at least that filenames are properly + + + + 29 September 2020 49 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + quoted. But it is possible that programs exist that only accept "\" on the command line, since that is the standard directory separator for MS-Windows. So for safety latexmk makes the sub- @@ -3226,18 +3258,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) viously running previewer on the same file, and if one is run- ning will not start a new one. If $new_viewer_always is non- zero, this check will be skipped, and latexmk will behave as if - - - - 13 September 2020 49 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - no viewer is running. $out_dir [""] @@ -3271,8 +3291,20 @@ LATEXMK(1) General Commands Manual LATEXMK(1) and you need to use makeindex or bibtex, then you need to dis- able the security measures (and assume any risks). One way of doing this is to temporarily set an operating system environment - variable openout_any to "a" (as in "all"), to override the de- - fault "paranoid" setting. + variable openout_any to "a" (as in "all"), to override the + + + + 29 September 2020 50 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + + default "paranoid" setting. $pdf_mode [0] If zero, do NOT generate a pdf version of the document. If @@ -3292,18 +3324,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) made. In $pdf_mode=3, it is ensured that a .dvi file is also made. But this may be overridden by the document. - - - - 13 September 2020 50 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $pdflatex ["pdflatex %O %S"] Specifies the command line for the LaTeX processing program in a version that makes a pdf file instead of a dvi file. @@ -3338,6 +3358,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) See details of the %latex_input_extensions for other information that equally applies to %pdflatex_input_extensions. + + + + 29 September 2020 51 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $pdflatex_silent_switch ["-interaction=batchmode"] Switch(es) for the pdflatex program (specified in the variable $pdflatex) when silent mode is on. @@ -3359,17 +3391,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) file. By default, for pdf files this association is to OS-X's preview, which is quite satisfactory. - - - 13 September 2020 51 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - WARNING: Problem under MS-Windows: if acroread is used as the pdf previewer, and it is actually viewing a pdf file, the pdf file cannot be updated. Thus makes acroread a bad choice of @@ -3404,6 +3425,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Note that acroread under MS-Windows (but not UNIX) locks the pdf file, so the default value is then 3. + + + 29 September 2020 52 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + Arranging to use a command to get a previewer explicitly updated requires three variables to be set. For example: @@ -3424,18 +3456,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) variable $pdf_update_method. The default value is the one ap- propriate for gv on a UNIX system. - - - - 13 September 2020 52 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $pid_position[1 under UNIX, -1 under MS-Windows] The variable $pid_position is used to specify which word in lines of the output from $pscmd corresponds to the process ID. @@ -3471,6 +3491,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) + + + 29 September 2020 53 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $preview_continuous_mode [0] If nonzero, run a previewer to view the document, and continue running latexmk to keep .dvi up-to-date. Equivalent to the -pvc @@ -3489,19 +3520,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) mended not to be set from an RC file, otherwise you could waste lots of paper. - - - - - 13 September 2020 53 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $print_type = ["auto"] Type of file to printout: possibilities are "auto", "dvi", "none", "pdf", or "ps". See the option -print= for the meaning @@ -3538,6 +3556,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Note that gv could be used with the -watch option updates its display whenever the postscript file changes, whereas ghostview + + + + 29 September 2020 54 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + does not. However, different versions of gv have slightly dif- ferent ways of writing this option. You can configure this variable appropriately. @@ -3557,17 +3587,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) in yourself, whenever it is needed. - - - 13 September 2020 54 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $ps_previewer_landscape ["start gv -swap %O %S", but start %O %S under MS-Windows] The command to invoke a ps-previewer in landscape mode. @@ -3604,6 +3623,17 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The period of inactivity, in minutes, after which pvc mode times out. This is used if $pvc_timeout is nonzero. + + + 29 September 2020 55 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $pvc_view_file_via_temporary [1] The same as $always_view_file_via_temporary, except that it only applies in preview-continuous mode (-pvc option). @@ -3623,17 +3653,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) correctly treated by the operating system in passing arguments to programs.) - - - 13 September 2020 55 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $recorder [1] Whether to use the -recorder option to (latex Use of this option results in a file of extension .fls containing a list of the @@ -3669,6 +3688,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) output or aux directories.] The default under MSWin and Cygwin is ';' and under UNIX-like + + + + 29 September 2020 56 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + operating systems (including Linux and OS-X) is ':'. Normally the defaults give correct behavior. But there can be difficul- ties if your operating system is of one kind, but some of your @@ -3688,18 +3719,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) silent mode isn't also set), and this is useful to locate unde- fined citations and references without searching through the much more verbose log file or the screen output of *latex. But - - - - 13 September 2020 56 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - the summary can also be excessively annoying. The default is not to give these warnings. The command line options -si- lence_logfile_warning_list and -silence_logfile_warning_list- @@ -3734,6 +3753,19 @@ LATEXMK(1) General Commands Manual LATEXMK(1) $success_cmd [undefined] See the documentation for $compiling_cmd. + + + + + 29 September 2020 57 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $tmpdir [See below for default] Directory to store temporary files that latexmk may generate while running. @@ -3754,18 +3786,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) gram. Note that once a missing file has been made, no further calls to - - - - 13 September 2020 57 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - make will be made on a subsequent run of latexmk to update the file. Handling this problem is the job of a suitably defined Makefile. See the section "USING latexmk WITH make" for how to @@ -3800,6 +3820,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The default behavior is normally satisfactory in the usual edit- compile-edit cycle. But, for example, latexmk can also be used + + + + 29 September 2020 58 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + as part of a build process for some bigger project, e.g., for creating documentation in the build of a software application. Then it is often sensible to treat citation and reference warn- @@ -3821,17 +3853,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) that one or more of the commands isn't set.) - - - 13 September 2020 58 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - $xdvipdfmx ["xdvipdfmx -E -o %D %O %S"] The program to make a pdf file from an xdv file (used in con- @@ -3865,6 +3886,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) not been found, and the file is given without an extension. This typically happens when LaTeX commands of the form \in- put{file} or \includegraphics{figure}, when the relevant source + + + + 29 September 2020 59 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + file does not exist. In this situation, latexmk searches for custom dependencies to @@ -3885,19 +3918,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) - - - - - 13 September 2020 59 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - CUSTOM DEPENDENCIES In any RC file a set of custom dependencies can be set up to convert a file with one extension to a file with another. An example use of this @@ -3932,6 +3952,18 @@ CUSTOM DEPENDENCIES must: If non-zero, the file from which we are converting must exist, if it doesn't exist latexmk will give an error message and exit unless the -f option is specified. If must is zero and the file + + + + 29 September 2020 60 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + we are converting from doesn't exist, then no action is taken. Generally, the appropriate value of must is zero. @@ -3954,16 +3986,6 @@ CUSTOM DEPENDENCIES tom dependencies to be sent to the screen output. - - 13 September 2020 60 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - How custom dependencies are used: An instance of a custom dependency rule is created whenever latexmk de- tects that a run of *latex needs to read a file, like a graphics file, @@ -3996,6 +4018,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Note for advanced usage: The operating system's environment variable TEXINPUTS can be used to specify a search path for finding files by la- tex etc. Correspondingly, when a missing file is reported, latexmk + + + + 29 September 2020 61 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + looks in the directories specified in TEXINPUTS as well as in the cur- rent directory, to find a source file from which an instance of a cus- tom dependency can be used to make the missing file. @@ -4017,20 +4051,8 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The first line adds a custom dependency that converts a file with ex- tension "fig", as created by the xfig program, to an encapsulated post- - script file, with extension "eps". The remaining lines define a - - - - 13 September 2020 61 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - - subroutine that carries out the conversion. If a rule for converting + script file, with extension "eps". The remaining lines define a sub- + routine that carries out the conversion. If a rule for converting "fig" to "eps" files already exists (e.g., from a previously read-in initialization file), the latexmk will delete this rule before making the new one. @@ -4062,6 +4084,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) } Note 1: In the command lines given in the system commands in the above + + + + 29 September 2020 62 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + examples, double quotes have been inserted around the file names (im- plemented by '\"' in the Perl language). They immunize the running of the program against special characters in filenames. Very often these @@ -4084,18 +4118,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Note 3: The subroutines implementing custom dependencies in the exam- ples given just have a single line invoking an external program. That's the usual situation. But since the subroutines are in the Perl - - - - 13 September 2020 62 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - language, you can implement much more complicated processing if you need it. @@ -4127,13 +4149,25 @@ LATEXMK(1) General Commands Manual LATEXMK(1) file. This method has been available since very old versions of la- texmk, and many examples can be found, e.g., on the web. - However in later versions of latexmk the internal structure of the im- - plementation of its "rules" for the steps of processing, including cus- - tom dependencies, became much more powerful. The function implementing - a custom dependency is executed within a special context where a number - of extra variables and subroutines are defined. Publicly documented - ones, intended to be long-term stable, are listed below, under the - heading "Variables and subroutines for processing a rule". + However in later versions of latexmk the internal structure of the + + + + 29 September 2020 63 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + + implementation of its "rules" for the steps of processing, including + custom dependencies, became much more powerful. The function imple- + menting a custom dependency is executed within a special context where + a number of extra variables and subroutines are defined. Publicly doc- + umented ones, intended to be long-term stable, are listed below, under + the heading "Variables and subroutines for processing a rule". Examples of their use is given in the following examples, concerning multiple index files and glossaries. @@ -4150,18 +4184,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) follows: add_cus_dep( 'ndx', 'nnd', 0, 'ndx2nnd' ); - - - - 13 September 2020 63 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - sub ndx2nnd { return system( "makeindex -o \"$_[0].nnd\" \"$_[0].ndx\"" ); } @@ -4194,6 +4216,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) push @generated_exts, 'ndx', 'nnd', 'adx', 'and'; This last example uses the command specification in $makeindex, and so + + + + 29 September 2020 64 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + any customization you have made for the standard index also applies to your extra indexes. @@ -4215,24 +4249,12 @@ LATEXMK(1) General Commands Manual LATEXMK(1) Old Method of Defining Custom Dependencies: In much older versions of latexmk, the only method of defining custom - dependencies was to directly manipulate the table of custom - - - - 13 September 2020 64 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - - dependencies. This is contained in the @cus_dep_list array. It is an - array of strings, and each string in the array has four items in it, - each separated by a space, the from-extension, the to-extension, the - "must" item, and the name of the subroutine for the custom dependency. - These were all defined above. + dependencies was to directly manipulate the table of custom dependen- + cies. This is contained in the @cus_dep_list array. It is an array of + strings, and each string in the array has four items in it, each sepa- + rated by a space, the from-extension, the to-extension, the "must" + item, and the name of the subroutine for the custom dependency. These + were all defined above. An example of the old method of defining custom dependencies is as fol- lows. It is the code in an RC file to ensure automatic conversion of @@ -4259,8 +4281,20 @@ ADVANCED CONFIGURATION: Some extra resources and advanced tricks See also the section DEALING WITH ERRORS, PROBLEMS, ETC. See also the examples in the directory example_rcfiles in the latexmk distributions. - Even if none of the examples apply to your case, they may give you use- - ful ideas + Even if none of the examples apply to your case, they may give you + + + + 29 September 2020 65 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + + useful ideas Utility subroutines @@ -4283,17 +4317,6 @@ ADVANCED CONFIGURATION: Some extra resources and advanced tricks to mean that *latex search for files in the specified directory and in all subdirectories.) - - - 13 September 2020 65 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - Technically ensure_path works by setting Perl's variable $ENV{var}, where var is the name of the target variable. The changed value is then passed as an environment variable to any @@ -4324,6 +4347,19 @@ LATEXMK(1) General Commands Manual LATEXMK(1) This gives the name of the primary source file. Note the double dollar signs. + + + + + 29 September 2020 66 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $$Pdest This gives the name of the main output file if any. Note the double dollar signs. @@ -4348,18 +4384,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) This subroutine removes one or more files from the dependency list for the given rule. - - - - 13 September 2020 66 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - rdb_list_source( $rule ) This subroutine returns the list of source files (i.e., the de- pendency list) for the given rule. @@ -4390,6 +4414,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) pattern, you can use one of the following subroutines, std_tex_cmds, alt_tex_cmds, and set_tex_cmds. + + + + 29 September 2020 67 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + They work as follows &std_tex_cmds; @@ -4413,19 +4449,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) set_tex_cmds( '--interaction=batchmode %O %S' ); - - - - - 13 September 2020 67 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - Advanced configuration: Using latexmk with make This section is targeted only at advanced users who use the make pro- gram for complex projects, as for software development, with the depen- @@ -4456,9 +4479,21 @@ LATEXMK(1) General Commands Manual LATEXMK(1) could be quite complicated, for example if some of the source files for a LaTeX document are generated by the project's software. - In this section, I give a couple of examples of how latexmk can be use- - fully invoked from a Makefile. The examples use specific features of - current versions of GNU make, which is the default on both linux and + In this section, I give a couple of examples of how latexmk can be + + + + 29 September 2020 68 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + + usefully invoked from a Makefile. The examples use specific features + of current versions of GNU make, which is the default on both linux and OS-X systems. They may need modifications for other versions of make. The simplest method is simply to delegate all the relevant tasks to la- @@ -4480,18 +4515,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) The above example has a pattern rule for making a .pdf file from a .tex file, and it is defined to use latexmk in the obvious way. There is a - - - - 13 September 2020 68 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - conventional default target named "all", with a prerequisite of try.pdf. So when make is invoked, by default it makes try.pdf. The only complication is that there may be many source files beyond @@ -4523,6 +4546,18 @@ LATEXMK(1) General Commands Manual LATEXMK(1) mkdir $@ %.pdf : %.tex if [ ! -e $(DEPS_DIR) ]; then mkdir $(DEPS_DIR); fi + + + + 29 September 2020 69 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + $(LATEXMK) -pdf -dvi- -ps- -deps-out=$(DEPS_DIR)/$@P $< %.pdf : %.fig fig2dev -Lpdf $< $@ @@ -4546,18 +4581,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) tion, which improves its detection of files generated during a run of pdflatex; such files should not be in the dependency list. The -e op- tions are used to turn off all custom dependencies, and to document - - - - 13 September 2020 69 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - this. Instead the -use-make is used to delegate the making of missing files to make itself. @@ -4589,6 +4612,18 @@ BUGS manual update (reopen); it views postscript and pdf. Gsview under MS- Windows works for both postscript and pdf, but only reads the updated file when its screen is refreshed. Acroread under UNIX/Linux views + + + + 29 September 2020 70 + + + + + +LATEXMK(1) General Commands Manual LATEXMK(1) + + pdf, but the file needs to be closed and reopened to view an updated version. Under MS-Windows, acroread locks its input file and so the pdf file cannot be updated. (Remedy: configure latexmk to use suma- @@ -4602,8 +4637,8 @@ THANKS TO dard form to avoid being harvested too easily.) AUTHOR - Current version, by John Collins (username jcc8 at node psu.edu). - (Version 4.70a). + Current version, by John Collins (Version 4.70b). Report bugs etc to + his e-mail (jcc8 at psu.edu). Released version can be obtained from CTAN: <http://www.ctan.org/pkg/latexmk/>, and from the author's website @@ -4615,41 +4650,6 @@ AUTHOR - 13 September 2020 70 - - - - - -LATEXMK(1) General Commands Manual LATEXMK(1) - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -4681,6 +4681,6 @@ LATEXMK(1) General Commands Manual LATEXMK(1) - 13 September 2020 71 + 29 September 2020 71 |