diff options
author | Karl Berry <karl@freefriends.org> | 2020-03-05 00:49:50 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2020-03-05 00:49:50 +0000 |
commit | 07ea488e2421f318a60191a7fe69692737301e7b (patch) | |
tree | 2bbb589e505d7275488a481a47cd624c4c8f37e2 /Master/texmf-dist/scripts/arara | |
parent | 7ddec71de13ffe715bfa197ad22ee03c165bb593 (diff) |
arara (4mar20)
git-svn-id: svn://tug.org/texlive/trunk@54089 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts/arara')
55 files changed, 748 insertions, 221 deletions
diff --git a/Master/texmf-dist/scripts/arara/arara.jar b/Master/texmf-dist/scripts/arara/arara.jar Binary files differindex c75f82e5be3..9e2c046ad18 100644 --- a/Master/texmf-dist/scripts/arara/arara.jar +++ b/Master/texmf-dist/scripts/arara/arara.jar diff --git a/Master/texmf-dist/scripts/arara/arara.sh b/Master/texmf-dist/scripts/arara/arara.sh index 197228f4916..12efa361a6b 100755 --- a/Master/texmf-dist/scripts/arara/arara.sh +++ b/Master/texmf-dist/scripts/arara/arara.sh @@ -3,7 +3,7 @@ # Note from Paulo: this script provides better Cygwin support than our original # approach, so the team decided to use it as a proper wrapper for arara as well. -scriptname=`basename "$0"` +scriptname=`basename "$0" .sh` jar="$scriptname.jar" jarpath=`kpsewhich --progname="$scriptname" --format=texmfscripts "$jar"` @@ -14,4 +14,4 @@ if echo "$kernel" | grep CYGWIN >/dev/null; then jarpath=`cygpath -w "$jarpath"` fi -exec java -jar "$jarpath" "$@" +exec java -jar "$jarpath" "$@"
\ No newline at end of file diff --git a/Master/texmf-dist/scripts/arara/rules/animate.yaml b/Master/texmf-dist/scripts/arara/rules/animate.yaml index ac6dc347bbe..d5baefa67d8 100644 --- a/Master/texmf-dist/scripts/arara/rules/animate.yaml +++ b/Master/texmf-dist/scripts/arara/rules/animate.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -8,14 +8,14 @@ identifier: animate name: Animate authors: - Chris Hughes -- Paulo Cereda +- Island of TeX commands: - name: The Convert program command: > @{ prefix = []; - input = getBasename(file).concat('.pdf'); - output = getBasename(file).concat('.gif'); + input = getBasename(reference).concat('.pdf'); + output = getBasename(reference).concat('.gif'); if (isUnix()) { prefix = [ program ]; } diff --git a/Master/texmf-dist/scripts/arara/rules/asymptote.yaml b/Master/texmf-dist/scripts/arara/rules/asymptote.yaml new file mode 100644 index 00000000000..c58e7dd0e5e --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/asymptote.yaml @@ -0,0 +1,62 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: asymptote +name: Asymptote +authors: +- Island of TeX +commands: +- name: Asymptote + command: > + @{ + return getCommand('asy', color, engine, twice, + format, output, options, file); + } +arguments: +- identifier: color + flag: > + @{ + if ([ 'bw', 'cmyk', 'rgb', 'gray' ].contains(parameters.color)) { + return '-' + parameters.color; + } else { + throwError('The provided color enforcement is not valid.'); + } + } +- identifier: engine + flag: > + @{ + if ([ 'latex', 'pdflatex' , 'xelatex', 'lualatex', 'tex', 'pdftex', + 'luatex', 'context', 'none' ].contains(parameters.engine)) { + return [ '-tex', parameters.engine ]; + } else { + throwError('The provided TeX engine is invalid.'); + } + } + default: latex +- identifier: twice + flag: > + @{ + return isTrue(parameters.twice, '-twice'); + } +- identifier: format + flag: > + @{ + return [ '-f', parameters.format ]; + } +- identifier: output + flag: > + @{ + return [ '-o', parameters.output ]; + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/bib2gls.yaml b/Master/texmf-dist/scripts/arara/rules/bib2gls.yaml index 9a979207172..a33744faec9 100644 --- a/Master/texmf-dist/scripts/arara/rules/bib2gls.yaml +++ b/Master/texmf-dist/scripts/arara/rules/bib2gls.yaml @@ -1,14 +1,13 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: bib2gls name: Bib2Gls authors: -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The Bib2Gls software command: > @@ -23,7 +22,7 @@ commands: prefix = [ 'cmd', '/c', 'del' ]; } - base = getBasename(file); + base = getBasename(reference); removals = []; lines = readFromFile(base.concat('.').concat('aux')); @@ -63,7 +62,7 @@ commands: return getCommand('bib2gls', dir, trans, group, interpret, breakspace, trimfields, recordcount, recordcountunit, cite, verbose, merge, locale, uniscript, packages, - ignore, custom, mapformats, options, getBasename(file)); + ignore, custom, mapformats, options, getBasename(reference)); } } arguments: @@ -80,7 +79,7 @@ arguments: throwError('Forbidden transcript extension'); } - return ['--log-file', getBasename(file)+"."+parameters.trans] + return ['--log-file', getBasename(reference)+"."+parameters.trans] } - identifier: locale flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/biber.yaml b/Master/texmf-dist/scripts/arara/rules/biber.yaml index 9ba02bc6b20..8cf9acb474d 100644 --- a/Master/texmf-dist/scripts/arara/rules/biber.yaml +++ b/Master/texmf-dist/scripts/arara/rules/biber.yaml @@ -1,21 +1,34 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: biber name: Biber authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The Biber reference management software command: > @{ - return getCommand('biber', options, getBasename(file)); + if (tool) { + return getCommand('biber', '--tool', options); + } + else { + return getCommand('biber', options, getBasename(file)); + } } arguments: +- identifier: tool + flag: > + @{ + return isTrue(parameters.tool); + } + default: > + @{ + return false; + } - identifier: options flag: > @{ diff --git a/Master/texmf-dist/scripts/arara/rules/bibtex.yaml b/Master/texmf-dist/scripts/arara/rules/bibtex.yaml index 5cbe5c17562..55dd1f0fec9 100644 --- a/Master/texmf-dist/scripts/arara/rules/bibtex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/bibtex.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: bibtex name: BibTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The BibTeX reference management software command: > @{ - return getCommand('bibtex', options, getBasename(file)) + return getCommand('bibtex', options, getBasename(reference)) } arguments: - identifier: options diff --git a/Master/texmf-dist/scripts/arara/rules/bibtex8.yaml b/Master/texmf-dist/scripts/arara/rules/bibtex8.yaml index 8a4631ff779..3741a920ea3 100644 --- a/Master/texmf-dist/scripts/arara/rules/bibtex8.yaml +++ b/Master/texmf-dist/scripts/arara/rules/bibtex8.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: bibtex8 name: BibTeX8 authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: An 8-bit implementation of BibTeX 0.99 with a very large capacity command: > @{ - return getCommand('bibtex8', options, getBasename(file)); + return getCommand('bibtex8', options, getBasename(reference)); } arguments: - identifier: options diff --git a/Master/texmf-dist/scripts/arara/rules/bibtexu.yaml b/Master/texmf-dist/scripts/arara/rules/bibtexu.yaml index f580886d95e..b1e6d181651 100644 --- a/Master/texmf-dist/scripts/arara/rules/bibtexu.yaml +++ b/Master/texmf-dist/scripts/arara/rules/bibtexu.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: bibtexu name: BibTeXu authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: An 8-bit implementation of BibTeX 0.99 with a very large capacity command: > @{ - return getCommand('bibtexu', options, getBasename(file)); + return getCommand('bibtexu', options, getBasename(reference)); } arguments: - identifier: options diff --git a/Master/texmf-dist/scripts/arara/rules/clean.yaml b/Master/texmf-dist/scripts/arara/rules/clean.yaml index 1a39ed3f27a..2a82eb3a87e 100644 --- a/Master/texmf-dist/scripts/arara/rules/clean.yaml +++ b/Master/texmf-dist/scripts/arara/rules/clean.yaml @@ -1,14 +1,13 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: clean name: Clean authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: Cleaning feature command: > @@ -21,13 +20,13 @@ commands: prefix = [ 'cmd', '/c', 'del' ]; } if (extensions == '') { - if (getOriginalFile() == file) { + if (getOriginalReference() == reference) { throwError('I cannot remove the main file reference.'); } - return getCommand(prefix, file); + return getCommand(prefix, reference); } else { - base = getBasename(file); + base = getBasename(reference); removals = []; foreach(extension : extensions) { if (base.concat('.').concat(extension) == getOriginalFile()) { diff --git a/Master/texmf-dist/scripts/arara/rules/csplain.yaml b/Master/texmf-dist/scripts/arara/rules/csplain.yaml index cfdcc954212..33e13c1a930 100644 --- a/Master/texmf-dist/scripts/arara/rules/csplain.yaml +++ b/Master/texmf-dist/scripts/arara/rules/csplain.yaml @@ -1,19 +1,19 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: csplain name: CSplain authors: -- Paulo Cereda +- Island of TeX commands: - name: CSplain engine command: > @{ return getCommand('csplain', interaction, draft, - shell, synctex, options, file); + shell, synctex, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/datatooltk.yaml b/Master/texmf-dist/scripts/arara/rules/datatooltk.yaml index 0b80d15e753..6fc08491c82 100644 --- a/Master/texmf-dist/scripts/arara/rules/datatooltk.yaml +++ b/Master/texmf-dist/scripts/arara/rules/datatooltk.yaml @@ -1,14 +1,13 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: datatooltk name: DatatoolTk authors: -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The DatatoolTk software command: > diff --git a/Master/texmf-dist/scripts/arara/rules/dvipdfm.yaml b/Master/texmf-dist/scripts/arara/rules/dvipdfm.yaml index d2dca0db363..e80fe5bf989 100644 --- a/Master/texmf-dist/scripts/arara/rules/dvipdfm.yaml +++ b/Master/texmf-dist/scripts/arara/rules/dvipdfm.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: dvipdfm name: DVIPDFM authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The DVIPDFM program command: > @{ - base = getBasename(file).concat('.dvi'); + base = getBasename(reference).concat('.dvi'); out = getBasename(output).concat('.pdf'); return getCommand('dvipdfm', base, '-o', out, options); } @@ -25,7 +24,7 @@ arguments: } default: > @{ - file + reference } - identifier: options flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/dvipdfmx.yaml b/Master/texmf-dist/scripts/arara/rules/dvipdfmx.yaml index 2feb9f0fe91..e4af77204b0 100644 --- a/Master/texmf-dist/scripts/arara/rules/dvipdfmx.yaml +++ b/Master/texmf-dist/scripts/arara/rules/dvipdfmx.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: dvipdfmx name: DVIPDFMX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The DVIPDFMX program command: > @{ - base = getBasename(file).concat('.dvi'); + base = getBasename(reference).concat('.dvi'); out = getBasename(output).concat('.pdf'); return getCommand('dvipdfmx', base, '-o', out, options); } @@ -25,7 +24,7 @@ arguments: } default: > @{ - file + reference } - identifier: options flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/dvips.yaml b/Master/texmf-dist/scripts/arara/rules/dvips.yaml index dd7a929bd0c..c110f19679f 100644 --- a/Master/texmf-dist/scripts/arara/rules/dvips.yaml +++ b/Master/texmf-dist/scripts/arara/rules/dvips.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: dvips name: DVIPS authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The DVIPS program command: > @{ - base = getBasename(file).concat('.dvi'); + base = getBasename(reference).concat('.dvi'); out = getBasename(output).concat('.ps'); return getCommand('dvips', base, '-o', out, options); } @@ -25,7 +24,7 @@ arguments: } default: > @{ - file + reference } - identifier: options flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/dvipspdf.yaml b/Master/texmf-dist/scripts/arara/rules/dvipspdf.yaml index 4190b1869c9..52df9731dfa 100644 --- a/Master/texmf-dist/scripts/arara/rules/dvipspdf.yaml +++ b/Master/texmf-dist/scripts/arara/rules/dvipspdf.yaml @@ -1,26 +1,25 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: dvipspdf name: DVIPSPDF authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The DVIPS program command: > @{ - base = getBasename(file).concat('.dvi'); - out = getBasename(file).concat('.ps'); + base = getBasename(reference).concat('.dvi'); + out = getBasename(reference).concat('.ps'); return getCommand('dvips', base, '-o', out, options1); } - name: The PS2PDF program command: > @{ - base = getBasename(file).concat('.ps'); + base = getBasename(reference).concat('.ps'); out = getBasename(output).concat('.pdf'); return getCommand('ps2pdf', options2, base, '-o', out); } @@ -32,7 +31,7 @@ arguments: } default: > @{ - file + reference } - identifier: options1 flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/dvisvgm.yaml b/Master/texmf-dist/scripts/arara/rules/dvisvgm.yaml index 0b5377f29d0..34edc09c576 100644 --- a/Master/texmf-dist/scripts/arara/rules/dvisvgm.yaml +++ b/Master/texmf-dist/scripts/arara/rules/dvisvgm.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -12,7 +12,7 @@ commands: - name: The dvisvgm program command: > @{ - base = getBasename(file).concat('.dvi'); + base = getBasename(reference).concat('.dvi'); return getCommand('dvisvgm', base, options); } arguments: diff --git a/Master/texmf-dist/scripts/arara/rules/etex.yaml b/Master/texmf-dist/scripts/arara/rules/etex.yaml index 15f8bf54126..6145fad1122 100644 --- a/Master/texmf-dist/scripts/arara/rules/etex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/etex.yaml @@ -1,20 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: etex name: eTeX authors: -- Marco Daniel -- Paulo Cereda -- Nicola Talbot +- Island of TeX commands: - name: Extended TeX engine command: > @{ - return getCommand('etex', interaction, shell, options, file); + return getCommand('etex', interaction, shell, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/frontespizio.yaml b/Master/texmf-dist/scripts/arara/rules/frontespizio.yaml index 45f3a4bf4f9..a4637ff9f88 100644 --- a/Master/texmf-dist/scripts/arara/rules/frontespizio.yaml +++ b/Master/texmf-dist/scripts/arara/rules/frontespizio.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -9,23 +9,23 @@ name: Frontespizio authors: - Francesco Endrici - Enrico Gregorio -- Paulo Cereda +- Island of TeX commands: - name: The engine command: > @{ - return getCommand(engine, interaction, shell, options, file) + return getCommand(engine, interaction, shell, options, reference) } - name: The frontispiece command: > @{ - base = getBasename(file).concat('-frn'); + base = getBasename(reference).concat('-frn'); return getCommand(engine, interaction, shell, base); } - name: The DVIPS program command: > @{ - base = getBasename(file).concat('-frn'); + base = getBasename(reference).concat('-frn'); eps = base.concat('.eps'); return isTrue(engine == 'latex', getCommand('dvips', '-o', eps, base), ''); @@ -33,7 +33,7 @@ commands: - name: The engine command: > @{ - return getCommand(engine, interaction, shell, options, file); + return getCommand(engine, interaction, shell, options, reference); } arguments: - identifier: engine diff --git a/Master/texmf-dist/scripts/arara/rules/halt.yaml b/Master/texmf-dist/scripts/arara/rules/halt.yaml index 9d8aaa8aef8..1c14644bcbe 100644 --- a/Master/texmf-dist/scripts/arara/rules/halt.yaml +++ b/Master/texmf-dist/scripts/arara/rules/halt.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -8,11 +8,12 @@ identifier: halt name: Halt authors: - Heiko Oberdiek -- Paulo Cereda +- Island of TeX commands: - name: The halt trigger command: > @{ - return getTrigger('halt'); + halt(0); + return true; } arguments: [] diff --git a/Master/texmf-dist/scripts/arara/rules/indent.yaml b/Master/texmf-dist/scripts/arara/rules/indent.yaml index b1e182f0a76..5ef623c5dbf 100644 --- a/Master/texmf-dist/scripts/arara/rules/indent.yaml +++ b/Master/texmf-dist/scripts/arara/rules/indent.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -8,13 +8,13 @@ identifier: indent name: Indent authors: - Chris Hughes -- Paulo Cereda +- Island of TeX commands: - name: The latexindent.pl script command: > @{ return getCommand('latexindent', silent, trace, screenlog, - settings, cruft, overwrite, output, file, modifylinebreaks, + settings, cruft, overwrite, output, reference, modifylinebreaks, replacement, options, logfile); } arguments: diff --git a/Master/texmf-dist/scripts/arara/rules/knitr.yaml b/Master/texmf-dist/scripts/arara/rules/knitr.yaml new file mode 100644 index 00000000000..da17289db2d --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/knitr.yaml @@ -0,0 +1,58 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: knitr +name: knitr +authors: +- Adam Liter +- Island of TeX +commands: +- name: knitr + command: > + @{ + elements = []; + if (!isEmpty(tangle)) elements.add('tangle = ' + tangle); + if (!isEmpty(quiet)) elements.add('quiet = ' + quiet); + elements.add('envir = ' + envir); + elements.add('encoding = ' + encoding); + return getCommand('Rscript', '-e', + 'library(knitr); knit("' + file + '", ' + + 'output = ' + isEmpty(output, 'NULL', '"' + output + '"') + ', ' + + String.join(', ', elements) + ')'); + } +arguments: +- identifier: output + flag: > + @{ + return parameters.output; + } +- identifier: tangle + flag: > + @{ + if(isTrue(parameters.tangle) && !parameters.containsKey('output')) { + throwError('If you want to tangle the document, specify an output file.'); + } + else { + isTrue(parameters.tangle, 'TRUE', 'FALSE') + } + } +- identifier: quiet + flag: > + @{ + isTrue(parameters.quiet, 'TRUE', 'FALSE') + } +- identifier: envir + flag: > + @{ + return parameters.envir; + } + default: 'parent.frame()' +- identifier: encoding + flag: > + @{ + return parameters.encoding; + } + default: 'getOption("encoding")' diff --git a/Master/texmf-dist/scripts/arara/rules/latex.yaml b/Master/texmf-dist/scripts/arara/rules/latex.yaml index f1b9add4b33..b79c051c1de 100644 --- a/Master/texmf-dist/scripts/arara/rules/latex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/latex.yaml @@ -1,22 +1,32 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: latex name: LaTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: LaTeX engine command: > @{ - return getCommand('latex', interaction, draft, shell, - synctex, options, file); + return getCommand(branch, interaction, draft, shell, + synctex, options, reference); } arguments: +- identifier: branch + flag: > + @{ + engines = [ 'stable' : 'latex', 'developer' : 'latex-dev' ]; + if (engines.keySet().contains(parameters.branch)) { + return engines.get(parameters.branch); + } else { + throwError('The valid branch values are: ' + engines.keySet()); + } + } + default: 'latex' - identifier: interaction flag: > @{ diff --git a/Master/texmf-dist/scripts/arara/rules/latexmk.yaml b/Master/texmf-dist/scripts/arara/rules/latexmk.yaml index 452b116a2fc..61f0ff9d7be 100644 --- a/Master/texmf-dist/scripts/arara/rules/latexmk.yaml +++ b/Master/texmf-dist/scripts/arara/rules/latexmk.yaml @@ -1,15 +1,13 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: latexmk name: LaTeXmk authors: -- Marco Daniel -- Brent Longborough -- Paulo Cereda +- Island of TeX commands: - name: Tool LaTeXmk command: > @@ -19,7 +17,7 @@ commands: } else { return getCommand('latexmk', isEmpty(program, engine, - program), options, file); + program), options, reference); } } arguments: diff --git a/Master/texmf-dist/scripts/arara/rules/luahbtex.yaml b/Master/texmf-dist/scripts/arara/rules/luahbtex.yaml new file mode 100644 index 00000000000..3f851fad9ee --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/luahbtex.yaml @@ -0,0 +1,54 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: luahbtex +name: LuaHBTeX +authors: +- Island of TeX +commands: +- name: LuaHBTeX engine + command: > + @{ + return getCommand('luahbtex', interaction, draft, shell, + synctex, options, reference); + } +arguments: +- identifier: interaction + flag: > + @{ + if ([ 'batchmode', 'nonstopmode', 'scrollmode', + 'errorstopmode' ].contains(parameters.interaction)) { + return '--interaction='.concat(parameters.interaction); + } + else { + throwError('The provided interaction value is not valid.'); + } + } +- identifier: shell + flag: > + @{ + isTrue(parameters.shell, '--shell-escape', '--no-shell-escape') + } +- identifier: synctex + flag: > + @{ + isTrue(parameters.synctex, '--synctex=1', '--synctex=0') + } +- identifier: draft + flag: > + @{ + isTrue(parameters.draft, '--draftmode') + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/lualatex.yaml b/Master/texmf-dist/scripts/arara/rules/lualatex.yaml index 4c4628d2482..d9870976d1a 100644 --- a/Master/texmf-dist/scripts/arara/rules/lualatex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/lualatex.yaml @@ -1,22 +1,32 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: lualatex name: LuaLaTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: LuaLaTeX engine command: > @{ - return getCommand('lualatex', interaction, draft, shell, - synctex, options, file); + return getCommand(branch, interaction, draft, shell, + synctex, options, reference); } arguments: +- identifier: branch + flag: > + @{ + engines = [ 'stable' : 'lualatex', 'developer' : 'lualatex-dev' ]; + if (engines.keySet().contains(parameters.branch)) { + return engines.get(parameters.branch); + } else { + throwError('The valid branch values are: ' + engines.keySet()); + } + } + default: 'lualatex' - identifier: interaction flag: > @{ diff --git a/Master/texmf-dist/scripts/arara/rules/luatex.yaml b/Master/texmf-dist/scripts/arara/rules/luatex.yaml index 78840f6d96d..86c7556993f 100644 --- a/Master/texmf-dist/scripts/arara/rules/luatex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/luatex.yaml @@ -1,20 +1,19 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: luatex name: LuaTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: LuaTeX engine command: > @{ return getCommand('luatex', interaction, draft, shell, - synctex, options, file); + synctex, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/make.yaml b/Master/texmf-dist/scripts/arara/rules/make.yaml index 07e619aa2df..0298ae95bee 100644 --- a/Master/texmf-dist/scripts/arara/rules/make.yaml +++ b/Master/texmf-dist/scripts/arara/rules/make.yaml @@ -1,14 +1,13 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: make name: Make authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The Make program command: > diff --git a/Master/texmf-dist/scripts/arara/rules/makeglossaries.yaml b/Master/texmf-dist/scripts/arara/rules/makeglossaries.yaml index 562af6d149a..34c1c07002f 100644 --- a/Master/texmf-dist/scripts/arara/rules/makeglossaries.yaml +++ b/Master/texmf-dist/scripts/arara/rules/makeglossaries.yaml @@ -1,22 +1,20 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: makeglossaries name: MakeGlossaries authors: -- Marco Daniel -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The MakeGlossaries software command: > @{ if (isEmpty(clean)) { - return getCommand('makeglossaries', options, getBasename(file)); + return getCommand('makeglossaries', options, getBasename(reference)); } else { prefix = []; @@ -27,7 +25,7 @@ commands: prefix = [ 'cmd', '/c', 'del' ]; } - base = getBasename(file); + base = getBasename(reference); removals = []; removals.add(getCommand(prefix, base.concat(".glsdefs"))); diff --git a/Master/texmf-dist/scripts/arara/rules/makeglossarieslite.yaml b/Master/texmf-dist/scripts/arara/rules/makeglossarieslite.yaml index fc48090c668..d716e97b4ab 100644 --- a/Master/texmf-dist/scripts/arara/rules/makeglossarieslite.yaml +++ b/Master/texmf-dist/scripts/arara/rules/makeglossarieslite.yaml @@ -1,20 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: makeglossarieslite name: MakeGlossariesLite authors: -- Marco Daniel -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The MakeGlossariesLite software command: > @{ - return getCommand('makeglossaries-lite', options, getBasename(file)); + return getCommand('makeglossaries-lite', options, getBasename(reference)); } arguments: - identifier: options diff --git a/Master/texmf-dist/scripts/arara/rules/makeindex.yaml b/Master/texmf-dist/scripts/arara/rules/makeindex.yaml index 83f7e286d02..795075bce2a 100644 --- a/Master/texmf-dist/scripts/arara/rules/makeindex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/makeindex.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: makeindex name: MakeIndex authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The MakeIndex software command: > @{ - base = getBasename(file); + base = getBasename(reference); infile = base.concat('.').concat(input); outfile = [ '-o', base.concat('.').concat(output) ]; logfile = [ '-t', base.concat('.').concat(log) ]; diff --git a/Master/texmf-dist/scripts/arara/rules/metapost.yaml b/Master/texmf-dist/scripts/arara/rules/metapost.yaml new file mode 100644 index 00000000000..390d08a1406 --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/metapost.yaml @@ -0,0 +1,50 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: metapost +name: Metapost +authors: +- Island of TeX +commands: +- name: Metapost + command: > + @{ + return getCommand('mpost', interaction, numbersystem, + options, file); + } +arguments: +- identifier: interaction + flag: > + @{ + if ([ 'batchmode', 'nonstopmode', 'scrollmode', + 'errorstopmode' ].contains(parameters.interaction)) { + return '-interaction='.concat(parameters.interaction); + } + else { + throwError('The provided interaction value is not valid.'); + } + } +- identifier: numbersystem + flag: > + @{ + if ([ 'scaled', 'double', 'binary', + 'decimal' ].contains(parameters.numbersystem)) { + return '-numbersystem='.concat(parameters.numbersystem); + } + else { + throwError('The provided numbersystem value is not valid.'); + } + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/nomencl.yaml b/Master/texmf-dist/scripts/arara/rules/nomencl.yaml index 2a563b62664..a2c3acf468a 100644 --- a/Master/texmf-dist/scripts/arara/rules/nomencl.yaml +++ b/Master/texmf-dist/scripts/arara/rules/nomencl.yaml @@ -1,21 +1,19 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: nomencl name: Nomencl authors: -- Marco Daniel -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The Nomenclature software command: > @{ - nlo = getBasename(file).concat('.nlo'); - nls = getBasename(file).concat('.nls'); + nlo = getBasename(reference).concat('.nlo'); + nls = getBasename(reference).concat('.nls'); return getCommand('makeindex', options, nlo, style, '-o', nls); } arguments: diff --git a/Master/texmf-dist/scripts/arara/rules/pbibtex.yaml b/Master/texmf-dist/scripts/arara/rules/pbibtex.yaml new file mode 100644 index 00000000000..9b39451d4d3 --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/pbibtex.yaml @@ -0,0 +1,27 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: pbibtex +name: pBibTeX +authors: +- Island of TeX +commands: +- name: The pBibTeX reference management software + command: > + @{ + return getCommand('pbibtex', options, getBasename(reference)) + } +arguments: +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/pdfcsplain.yaml b/Master/texmf-dist/scripts/arara/rules/pdfcsplain.yaml index db9bbdbec50..6dc6d287f49 100644 --- a/Master/texmf-dist/scripts/arara/rules/pdfcsplain.yaml +++ b/Master/texmf-dist/scripts/arara/rules/pdfcsplain.yaml @@ -1,19 +1,19 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: pdfcsplain name: PDFCSplain authors: -- Paulo Cereda +- Island of TeX commands: - name: PDFCSplain engine command: > @{ return getCommand('pdfcsplain', interaction, draft, shell, - synctex, options, file); + synctex, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/pdflatex.yaml b/Master/texmf-dist/scripts/arara/rules/pdflatex.yaml index 61b9b8d3560..3df1135dfa9 100644 --- a/Master/texmf-dist/scripts/arara/rules/pdflatex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/pdflatex.yaml @@ -1,22 +1,32 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: pdflatex name: PDFLaTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: PDFLaTeX engine command: > @{ - return getCommand('pdflatex', interaction, draft, shell, - synctex, options, file); + return getCommand(branch, interaction, draft, shell, + synctex, options, reference); } arguments: +- identifier: branch + flag: > + @{ + engines = [ 'stable' : 'pdflatex', 'developer' : 'pdflatex-dev' ]; + if (engines.keySet().contains(parameters.branch)) { + return engines.get(parameters.branch); + } else { + throwError('The valid branch values are: ' + engines.keySet()); + } + } + default: 'pdflatex' - identifier: interaction flag: > @{ diff --git a/Master/texmf-dist/scripts/arara/rules/pdftex.yaml b/Master/texmf-dist/scripts/arara/rules/pdftex.yaml index 2e3126bbfdc..8b10bc02f56 100644 --- a/Master/texmf-dist/scripts/arara/rules/pdftex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/pdftex.yaml @@ -1,20 +1,19 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: pdftex name: PDFTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: PDFTeX engine command: > @{ return getCommand('pdftex', interaction, draft, shell, - synctex, options, file); + synctex, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/pdftk.yaml b/Master/texmf-dist/scripts/arara/rules/pdftk.yaml index 9bd3f460600..67e81f0bd4d 100644 --- a/Master/texmf-dist/scripts/arara/rules/pdftk.yaml +++ b/Master/texmf-dist/scripts/arara/rules/pdftk.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: pdftk name: PDFtk authors: -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: PDFtk command: > @{ - input = getBasename(file).concat('.pdf'); + input = getBasename(reference).concat('.pdf'); return getCommand('pdftk', input, options); } arguments: diff --git a/Master/texmf-dist/scripts/arara/rules/platex.yaml b/Master/texmf-dist/scripts/arara/rules/platex.yaml new file mode 100644 index 00000000000..3a592687539 --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/platex.yaml @@ -0,0 +1,60 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: platex +name: pLaTeX +authors: +- Island of TeX +commands: +- name: pLaTeX engine + command: > + @{ + return getCommand(branch, interaction, shell, + synctex, options, reference); + } +arguments: +- identifier: branch + flag: > + @{ + engines = [ 'stable' : 'platex', 'developer' : 'platex-dev' ]; + if (engines.keySet().contains(parameters.branch)) { + return engines.get(parameters.branch); + } else { + throwError('The valid branch values are: ' + engines.keySet()); + } + } + default: 'platex' +- identifier: interaction + flag: > + @{ + if ([ 'batchmode', 'nonstopmode', 'scrollmode', + 'errorstopmode' ].contains(parameters.interaction)) { + return '--interaction='.concat(parameters.interaction); + } + else { + throwError('The provided interaction value is not valid.'); + } + } +- identifier: shell + flag: > + @{ + isTrue(parameters.shell, '--shell-escape', '--no-shell-escape') + } +- identifier: synctex + flag: > + @{ + isTrue(parameters.synctex, '--synctex=1', '--synctex=0') + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/ps2pdf.yaml b/Master/texmf-dist/scripts/arara/rules/ps2pdf.yaml index 656f7e22c31..fe5684d1c2b 100644 --- a/Master/texmf-dist/scripts/arara/rules/ps2pdf.yaml +++ b/Master/texmf-dist/scripts/arara/rules/ps2pdf.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: ps2pdf name: PS2PDF authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The PS2PDF program command: > @{ - infile = getBasename(file).concat('.ps'); + infile = getBasename(reference).concat('.ps'); outfile = getBasename(output).concat('.pdf'); return getCommand('ps2pdf', options, infile, outfile); } @@ -25,7 +24,7 @@ arguments: } default: > @{ - file + reference } - identifier: options flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/ptex.yaml b/Master/texmf-dist/scripts/arara/rules/ptex.yaml new file mode 100644 index 00000000000..3771981e7f6 --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/ptex.yaml @@ -0,0 +1,49 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: ptex +name: pTeX +authors: +- Island of TeX +commands: +- name: pTeX engine + command: > + @{ + return getCommand('ptex', interaction, shell, + synctex, options, reference); + } +arguments: +- identifier: interaction + flag: > + @{ + if ([ 'batchmode', 'nonstopmode', 'scrollmode', + 'errorstopmode' ].contains(parameters.interaction)) { + return '--interaction='.concat(parameters.interaction); + } + else { + throwError('The provided interaction value is not valid.'); + } + } +- identifier: shell + flag: > + @{ + isTrue(parameters.shell, '--shell-escape', '--no-shell-escape') + } +- identifier: synctex + flag: > + @{ + isTrue(parameters.synctex, '--synctex=1', '--synctex=0') + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/sketch.yaml b/Master/texmf-dist/scripts/arara/rules/sketch.yaml index a170aa20f2d..ca3d22834a2 100644 --- a/Master/texmf-dist/scripts/arara/rules/sketch.yaml +++ b/Master/texmf-dist/scripts/arara/rules/sketch.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -8,13 +8,13 @@ identifier: sketch name: Sketch authors: - Sergey Ulyanov -- Paulo Cereda +- Island of TeX commands: - name: The Sketch software command: > @{ - output = getBasename(file).concat('.tex'); - return getCommand('sketch', options, file, '-o', output); + output = getBasename(reference).concat('.tex'); + return getCommand('sketch', options, reference, '-o', output); } arguments: - identifier: options diff --git a/Master/texmf-dist/scripts/arara/rules/songidx.yaml b/Master/texmf-dist/scripts/arara/rules/songidx.yaml index 818c4333a77..ff4a27e6b8f 100644 --- a/Master/texmf-dist/scripts/arara/rules/songidx.yaml +++ b/Master/texmf-dist/scripts/arara/rules/songidx.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -8,7 +8,7 @@ identifier: songidx name: SongIDX authors: - Francesco Endrici -- Paulo Cereda +- Island of TeX commands: - name: The SongIDX Lua script command: > diff --git a/Master/texmf-dist/scripts/arara/rules/tex.yaml b/Master/texmf-dist/scripts/arara/rules/tex.yaml index c0321b34dce..701d2000962 100644 --- a/Master/texmf-dist/scripts/arara/rules/tex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/tex.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: tex name: TeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: TeX engine command: > @{ - return getCommand('tex', interaction, shell, options, file); + return getCommand('tex', interaction, shell, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/texindy.yaml b/Master/texmf-dist/scripts/arara/rules/texindy.yaml index d527e0292d2..54b468d42ac 100644 --- a/Master/texmf-dist/scripts/arara/rules/texindy.yaml +++ b/Master/texmf-dist/scripts/arara/rules/texindy.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: texindy name: TeXindy authors: -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The TeXindy software command: > @{ - base = getBasename(file); + base = getBasename(reference); infile = base.concat('.').concat(input); outfile = [ '-o', base.concat('.').concat(output) ]; logfile = [ '-t', base.concat('.').concat(log) ]; diff --git a/Master/texmf-dist/scripts/arara/rules/tikzmake.yaml b/Master/texmf-dist/scripts/arara/rules/tikzmake.yaml index e6cb809a54e..97942aaa3ba 100644 --- a/Master/texmf-dist/scripts/arara/rules/tikzmake.yaml +++ b/Master/texmf-dist/scripts/arara/rules/tikzmake.yaml @@ -1,6 +1,6 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. @@ -8,12 +8,12 @@ identifier: tikzmake name: TikZmake authors: - Robbie Smith -- Paulo Cereda +- Island of TeX commands: - name: TikZ list-and-make engine command: > @{ - makefile = getBasename(file).concat('.makefile'); + makefile = getBasename(reference).concat('.makefile'); return getCommand('make', force, jobs, options, '-f', makefile); } arguments: diff --git a/Master/texmf-dist/scripts/arara/rules/upbibtex.yaml b/Master/texmf-dist/scripts/arara/rules/upbibtex.yaml new file mode 100644 index 00000000000..eb0f5fba9db --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/upbibtex.yaml @@ -0,0 +1,27 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: upbibtex +name: upBibTeX +authors: +- Island of TeX +commands: +- name: The upBibTeX reference management software + command: > + @{ + return getCommand('upbibtex', options, getBasename(reference)) + } +arguments: +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/uplatex.yaml b/Master/texmf-dist/scripts/arara/rules/uplatex.yaml new file mode 100644 index 00000000000..0fd1d575f9a --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/uplatex.yaml @@ -0,0 +1,60 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: uplatex +name: upLaTeX +authors: +- Island of TeX +commands: +- name: upLaTeX engine + command: > + @{ + return getCommand(branch, interaction, shell, + synctex, options, reference); + } +arguments: +- identifier: branch + flag: > + @{ + engines = [ 'stable' : 'uplatex', 'developer' : 'uplatex-dev' ]; + if (engines.keySet().contains(parameters.branch)) { + return engines.get(parameters.branch); + } else { + throwError('The valid branch values are: ' + engines.keySet()); + } + } + default: 'uplatex' +- identifier: interaction + flag: > + @{ + if ([ 'batchmode', 'nonstopmode', 'scrollmode', + 'errorstopmode' ].contains(parameters.interaction)) { + return '--interaction='.concat(parameters.interaction); + } + else { + throwError('The provided interaction value is not valid.'); + } + } +- identifier: shell + flag: > + @{ + isTrue(parameters.shell, '--shell-escape', '--no-shell-escape') + } +- identifier: synctex + flag: > + @{ + isTrue(parameters.synctex, '--synctex=1', '--synctex=0') + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/uptex.yaml b/Master/texmf-dist/scripts/arara/rules/uptex.yaml new file mode 100644 index 00000000000..b2c9c90fe70 --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/uptex.yaml @@ -0,0 +1,49 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: uptex +name: upTeX +authors: +- Island of TeX +commands: +- name: upTeX engine + command: > + @{ + return getCommand('uptex', interaction, shell, + synctex, options, reference); + } +arguments: +- identifier: interaction + flag: > + @{ + if ([ 'batchmode', 'nonstopmode', 'scrollmode', + 'errorstopmode' ].contains(parameters.interaction)) { + return '--interaction='.concat(parameters.interaction); + } + else { + throwError('The provided interaction value is not valid.'); + } + } +- identifier: shell + flag: > + @{ + isTrue(parameters.shell, '--shell-escape', '--no-shell-escape') + } +- identifier: synctex + flag: > + @{ + isTrue(parameters.synctex, '--synctex=1', '--synctex=0') + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } + else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/velocity.yaml b/Master/texmf-dist/scripts/arara/rules/velocity.yaml deleted file mode 100644 index 0fd62a94650..00000000000 --- a/Master/texmf-dist/scripts/arara/rules/velocity.yaml +++ /dev/null @@ -1,41 +0,0 @@ -!config -# Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda -# All rights reserved. -# -# This rule is part of arara. -identifier: velocity -name: Velocity -authors: -- Paulo Cereda -commands: -- name: The Velocity engine - command: > - @{ - mergeVelocityTemplate(isEmpty(input, reference, toFile(input)), - toFile(output), context); - return true; - } -arguments: -- identifier: context - flag: > - @{ - if (isMap(parameters.context)) { - return parameters.context; - } - else { - throwError('I was expecting a context map.'); - } - } - required: true -- identifier: output - flag: > - @{ - return parameters.output; - } - required: true -- identifier: input - flag: > - @{ - return parameters.input; - } diff --git a/Master/texmf-dist/scripts/arara/rules/xdvipdfmx.yaml b/Master/texmf-dist/scripts/arara/rules/xdvipdfmx.yaml index b9433f8a939..bf67572fc34 100644 --- a/Master/texmf-dist/scripts/arara/rules/xdvipdfmx.yaml +++ b/Master/texmf-dist/scripts/arara/rules/xdvipdfmx.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: xdvipdfmx name: XDVIPDFMX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: The XDVIPDFMX program command: > @{ - infile = getBasename(file).concat('.dvi'); + infile = getBasename(reference).concat('.dvi'); outfile = getBasename(output).concat('.pdf'); return getCommand('xdvipdfmx', infile, '-o', outfile, options); } @@ -25,7 +24,7 @@ arguments: } default: > @{ - file + reference } - identifier: options flag: > diff --git a/Master/texmf-dist/scripts/arara/rules/xelatex.yaml b/Master/texmf-dist/scripts/arara/rules/xelatex.yaml index e248ae2fe87..ef1e1a8f0a0 100644 --- a/Master/texmf-dist/scripts/arara/rules/xelatex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/xelatex.yaml @@ -1,22 +1,32 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: xelatex name: XeLaTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: XeLaTeX engine command: > @{ - return getCommand('xelatex', interaction, shell, - synctex, options, file); + return getCommand(branch, interaction, shell, + synctex, options, reference); } arguments: +- identifier: branch + flag: > + @{ + engines = [ 'stable' : 'xelatex', 'developer' : 'xelatex-dev' ]; + if (engines.keySet().contains(parameters.branch)) { + return engines.get(parameters.branch); + } else { + throwError('The valid branch values are: ' + engines.keySet()); + } + } + default: 'xelatex' - identifier: interaction flag: > @{ diff --git a/Master/texmf-dist/scripts/arara/rules/xetex.yaml b/Master/texmf-dist/scripts/arara/rules/xetex.yaml index 2a9369e0e87..0d13768a285 100644 --- a/Master/texmf-dist/scripts/arara/rules/xetex.yaml +++ b/Master/texmf-dist/scripts/arara/rules/xetex.yaml @@ -1,20 +1,19 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: xetex name: XeTeX authors: -- Marco Daniel -- Paulo Cereda +- Island of TeX commands: - name: XeTeX engine command: > @{ return getCommand('xetex', interaction, shell, - synctex, options, file); + synctex, options, reference); } arguments: - identifier: interaction diff --git a/Master/texmf-dist/scripts/arara/rules/xindex.yaml b/Master/texmf-dist/scripts/arara/rules/xindex.yaml new file mode 100644 index 00000000000..8ec73cf0688 --- /dev/null +++ b/Master/texmf-dist/scripts/arara/rules/xindex.yaml @@ -0,0 +1,49 @@ +!config +# Arara, the cool TeX automation tool +# Copyright (c) 2020, Island of TeX +# All rights reserved. +# +# This rule is part of arara. +identifier: xindex +name: xindex +authors: +- Island of TeX +commands: +- name: The xindex software + command: > + @{ + return getCommand('xindex', config, language, options, input); + } +arguments: +- identifier: input + flag: > + @{ + return parameters.input; + } +- identifier: config + flag: > + @{ + return [ '-c', parameters.config ]; + } + default: > + @{ + return [ '-c', 'cfg' ]; + } +- identifier: language + flag: > + @{ + return [ '-l', parameters.language ]; + } + default: > + @{ + return [ '-l', 'en' ]; + } +- identifier: options + flag: > + @{ + if (isList(parameters.options)) { + return parameters.options; + } else { + throwError('I was expecting a list of options.'); + } + } diff --git a/Master/texmf-dist/scripts/arara/rules/xindy.yaml b/Master/texmf-dist/scripts/arara/rules/xindy.yaml index 6daf807cc86..2efc37daf5d 100644 --- a/Master/texmf-dist/scripts/arara/rules/xindy.yaml +++ b/Master/texmf-dist/scripts/arara/rules/xindy.yaml @@ -1,19 +1,18 @@ !config # Arara, the cool TeX automation tool -# Copyright (c) 2018, Paulo Roberto Massa Cereda +# Copyright (c) 2020, Island of TeX # All rights reserved. # # This rule is part of arara. identifier: xindy name: Xindy authors: -- Nicola Talbot -- Paulo Cereda +- Island of TeX commands: - name: The Xindy software command: > @{ - base = getBasename(file); + base = getBasename(reference); infile = base.concat('.').concat(input); outfile = [ '-o', base.concat('.').concat(output) ]; logfile = [ '-t', base.concat('.').concat(log) ]; |