Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
2508cbf
Texstyles: mark the Theory of Probability and Mathematical Statistics…
oscarlevin Sep 29, 2026
a412eae
Script: unpack a required file when its "compression" is "zip", whate…
oscarlevin Sep 29, 2026
31b4f96
Texstyles: update Springer Nature required files href
oscarlevin Sep 29, 2026
290d471
Publication schema: "citation-stylesheet-language" element
oscarlevin Sep 29, 2026
d78fe0e
Script: a file of generated references not yet built reads as empty i…
oscarlevin Sep 29, 2026
8618339
Assembly: detect a missing file of generated references and citations
oscarlevin Sep 29, 2026
a715d1d
Assembly: citations come from the generated file at "$csl-file", in t…
oscarlevin Sep 29, 2026
0a978dd
Assembly: citations stay as authored when generated references are mi…
oscarlevin Sep 29, 2026
236e252
Script: name the references file in the error for a failed write
oscarlevin Sep 29, 2026
2b62a67
Publisher variables: a journal supplies the default CSL style
oscarlevin Sep 29, 2026
1e627fc
Journals: a CSL style for each supported journal with one
oscarlevin Sep 29, 2026
800fde4
Script: a journal may supply the CSL style for references, found by c…
oscarlevin Sep 29, 2026
35899f9
Script: report a CSL style citeproc-py cannot locate, rather than rai…
oscarlevin Sep 29, 2026
860ddb9
Texstyles: a bibliography is placed, and formatted by PreTeXt, with n…
oscarlevin Sep 29, 2026
5a0f570
Texstyles: place a bibliography without a warning, since PreTeXt form…
oscarlevin Sep 29, 2026
06c68e8
Journals: the table of supported journals reports each CSL style
oscarlevin Sep 29, 2026
58d5aef
Guide: a journal's CSL style, and choosing a style for references and…
oscarlevin Sep 29, 2026
182a610
Assembly: one switch decides whether generated references are consulted
oscarlevin Sep 29, 2026
4be592f
Publisher variables: the report never consults generated references
oscarlevin Sep 29, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 18 additions & 0 deletions doc/guide/appendices/journals-table.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,74 +24,92 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<row header="yes">
<cell>Full Journal Name</cell>
<cell>Code</cell>
<cell>Bibliography Style</cell>
</row>
<row bottom="minor">
<cell>AMS journals</cell>
<cell>ams</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Elsevier journals</cell>
<cell>elsevier</cell>
<cell>elsevier-with-titles</cell>
</row>
<row bottom="minor">
<cell>Springer Nature journals</cell>
<cell>springer-nature</cell>
<cell>springer-mathphys-brackets</cell>
</row>
<row bottom="minor">
<cell>Taylor Francis journals</cell>
<cell>taylor-francis</cell>
<cell>taylor-and-francis-numeric-q</cell>
</row>
<row bottom="minor">
<cell>Annals of Pure and Applied Logic</cell>
<cell>ann-pure-appl-logic</cell>
<cell>elsevier-with-titles</cell>
</row>
<row bottom="minor">
<cell>Bulletin (New Series) of the American Mathematical Society</cell>
<cell>bull-amer-math-soc</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Conformal Geometry and Dynamics</cell>
<cell>conform-geom-dyn</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Electronic Journal of Combinatorics</cell>
<cell>electron-j-combin</cell>
<cell>(none)</cell>
</row>
<row bottom="minor">
<cell>Experimental Mathematics</cell>
<cell>exp-math</cell>
<cell>taylor-and-francis-numeric-q</cell>
</row>
<row bottom="minor">
<cell>Journal of Algebraic Geometry</cell>
<cell>j-algebraic-geom</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Journal of the American Mathematical Society</cell>
<cell>j-amer-math-soc</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Mathematics of Computation</cell>
<cell>math-comp</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Quarterly of Applied Mathematics</cell>
<cell>quart-appl-math</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Proceedings of the American Mathematical Society</cell>
<cell>proc-amer-math-soc</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Representation Theory</cell>
<cell>represent-theory</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Theory of Probability and Mathematical Statistics</cell>
<cell>theory-probab-math-statist</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
<row bottom="minor">
<cell>Transactions of the American Mathematical Society</cell>
<cell>trans-ams</cell>
<cell>american-mathematical-society-numeric</cell>
</row>
</tabular>
</table>
8 changes: 8 additions & 0 deletions doc/guide/appendices/journals.xml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,14 @@
The code for a journal is taken from the list of abbreviations used by MathSciNet available at <url href="https://mathscinet.ams.org/msnhtml/serials.pdf">https://mathscinet.ams.org/msnhtml/serials.pdf</url>.
</p>

<p>
The third column gives the Citation Style Language (<init>CSL</init>) style that
naming the journal selects for the bibliography and citations. A journal listed
with <q>(none)</q> has no such style available, and its references are formatted by
<pretext/> in its usual way. See <xref ref="common-csl"/> to choose a style
yourself instead.
</p>

<xi:include href="journals-table.xml"/>

</appendix>
45 changes: 44 additions & 1 deletion doc/guide/publisher/publication-file.xml
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,50 @@

<p>
A complete list of the supported journals, together with their short name codes, will
be available in <xref ref="appendix-journals"/>.
be available in <xref ref="appendix-journals"/>. That list also gives each journal's
bibliography style, which naming the journal selects for your references and
citations, in every output format. See <xref ref="common-csl"/> for what that
requires, and for choosing a style yourself instead.
</p>
</subsection>

<subsection xml:id="common-csl">
<title>Bibliography and citation style</title>
<idx><h>common option</h><h>bibliography style</h></idx>
<idx><h>bibliography style</h><h>common option</h></idx>
<idx><h>citation style</h></idx>
<idx><h>CSL</h></idx>

<p>
The entries of a bibliography, and the citations that point to them, can be
formatted according to a style from the Citation Style Language
(<init>CSL</init>) repository, which describes the house styles of thousands of
journals and publishers. Name one with
<cd>
<cline>/publication/common/citation-stylesheet-language/@style</cline>
</cd>
whose value is a style's identifier, such as
<c>american-mathematical-society-numeric</c> or <c>apa</c>, without the
<c>.csl</c> suffix. The available styles can be browsed at
<url href="https://www.zotero.org/styles">https://www.zotero.org/styles</url>.
</p>

<p>
Naming a journal (<xref ref="common-journal"/>) selects that journal's style, so
you need not set this at all. When both are given, the style named here wins, which
is what you want when preparing a preprint of an article destined for a journal
whose <latex/> style you still wish to use.
</p>

<p>
Formatted references and citations are a generated asset. Generate them with
<c>pretext generate references</c> from the <init>CLI</init>, or with
<c>-c references</c> from the <c>pretext/pretext</c> script, and again whenever
you change the style or your references. Until then <pretext/> formats
references in its usual way, and says so. Formatting requires the
<c>citeproc-py</c> Python package, and the styles themselves come from the
<c>citeproc-py-styles</c> package, so install both. Styles that put citations
in footnotes or endnotes are not yet supported.
</p>
</subsection>

Expand Down
13 changes: 12 additions & 1 deletion journals/journals-to-table.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<title>Journals supported by PreTeXt</title>
<tabular>
<row header="yes">
<cell>Full Journal Name</cell><cell>Code</cell>
<cell>Full Journal Name</cell><cell>Code</cell><cell>Bibliography Style</cell>
</row>
<xsl:apply-templates select="journal"/>
</tabular>
Expand All @@ -40,6 +40,17 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<row bottom="minor">
<cell><xsl:value-of select="name"/></cell>
<cell><xsl:value-of select="code"/></cell>
<cell>
<xsl:choose>
<xsl:when test="citation-stylesheet-language/@style">
<xsl:value-of select="citation-stylesheet-language/@style"/>
</xsl:when>
<!-- no CSL style, so PreTeXt formats references -->
<xsl:otherwise>
<xsl:text>(none)</xsl:text>
</xsl:otherwise>
</xsl:choose>
</cell>
</row>
</xsl:template>

Expand Down
22 changes: 22 additions & 0 deletions journals/journals.xml
Original file line number Diff line number Diff line change
Expand Up @@ -21,48 +21,61 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<ptx-journals>
<!-- We might want some categories or other way to break these up? More likely just use tags -->

<!-- A journal's "citation-stylesheet-language/@style" is the Citation Style -->
<!-- Language (CSL) style for its references and citations, used when the -->
<!-- publication file names the journal and names no style of its own. A -->
<!-- journal with no counterpart among CSL styles has none, and its -->
<!-- references are formatted by PreTeXt in its usual way. -->

<journal>
<code>ams</code>
<name>AMS journals</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
</journal>

<journal>
<code>elsevier</code>
<name>Elsevier journals</name>
<publisher>Elsevier</publisher>
<citation-stylesheet-language style="elsevier-with-titles"/>
</journal>

<journal>
<code>springer-nature</code>
<name>Springer Nature journals</name>
<publisher>Springer Nature</publisher>
<citation-stylesheet-language style="springer-mathphys-brackets"/>
</journal>

<journal>
<code>taylor-francis</code>
<name>Taylor Francis journals</name>
<publisher>Taylor &amp; Francis</publisher>
<citation-stylesheet-language style="taylor-and-francis-numeric-q"/>
</journal>

<journal>
<code>ann-pure-appl-logic</code>
<name>Annals of Pure and Applied Logic</name>
<publisher>Elsevier</publisher>
<citation-stylesheet-language style="elsevier-with-titles"/>
<method texstyle="elsevier"/>
</journal>

<journal>
<code>bull-amer-math-soc</code>
<name>Bulletin (New Series) of the American Mathematical Society</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>conform-geom-dyn</code>
<name>Conformal Geometry and Dynamics</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

Expand All @@ -76,13 +89,15 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<code>exp-math</code>
<name>Experimental Mathematics</name>
<publisher>Taylor &amp; Francis</publisher>
<citation-stylesheet-language style="taylor-and-francis-numeric-q"/>
<method texstyle="taylor-francis"/>
</journal>

<journal>
<code>j-algebraic-geom</code>
<name>Journal of Algebraic Geometry</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

Expand All @@ -91,48 +106,55 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<code>j-amer-math-soc</code>
<name>Journal of the American Mathematical Society</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>math-comp</code>
<name>Mathematics of Computation</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>quart-appl-math</code>
<name>Quarterly of Applied Mathematics</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>proc-amer-math-soc</code>
<name>Proceedings of the American Mathematical Society</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>represent-theory</code>
<name>Representation Theory</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>theory-probab-math-statist</code>
<name>Theory of Probability and Mathematical Statistics</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

<journal>
<code>trans-ams</code>
<name>Transactions of the American Mathematical Society</name>
<publisher>American Mathematical Society</publisher>
<citation-stylesheet-language style="american-mathematical-society-numeric"/>
<method dependent="yes"/>
</journal>

Expand Down
5 changes: 1 addition & 4 deletions journals/texstyles/ams.xml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<name>AMS journals</name>
<publisher>American Mathematical Society</publisher>
<latex-engine command="pdflatex"/>
<bibliography-style>spbasic</bibliography-style>

<style-author>Oscar Levin</style-author>
<date>2025-03-12</date>
Expand Down Expand Up @@ -93,9 +92,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.

<appendices />

<bibliography cmd="bibliography">
<arg><bib-file/></arg>
</bibliography>
<bibliography/>

<end-document/>
</texstyle>
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<publisher>American Mathematical Society</publisher>
<extends>ams</extends>
<required-files>
<file name="tpms-l.cls" href="https://probability.knu.ua/tims/tpms_amslatex.zip" path="tpms_amslatex/tpms-l.cls"/>
<file name="tpms-l.cls" href="https://probability.knu.ua/tims/tpms_amslatex.zip" compression="zip" path="tpms_amslatex/tpms-l.cls"/>
</required-files>
<style-author>Oscar Levin</style-author>
<date>2025-03-12</date>
Expand Down
5 changes: 1 addition & 4 deletions journals/texstyles/electron-j-combin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
<file name="e-jc.sty" href="https://www.combinatorics.org/files/e-jc.sty" />
</required-files>
<latex-engine command="pdflatex"/>
<!--<bibliography-style>spbasic</bibliography-style>-->

<style-author>Oscar Levin</style-author>
<date>2025-03-23</date>
Expand Down Expand Up @@ -84,9 +83,7 @@
<appendices cmd="appendix"/>


<bibliography cmd="bibliography">
<arg><bib-file/></arg>
</bibliography>
<bibliography/>


<end-document/>
Expand Down
5 changes: 1 addition & 4 deletions journals/texstyles/elsevier.xml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<file href="https://resource-cms.springernature.com/springer-cms/rest/v1/content/18782940/data/v13.zip" compression="zip" path="sn-article-template/sn-jnl.cls"/>
</required-files>-->
<latex-engine command="pdflatex"/>
<!--<bibliography-style>spbasic</bibliography-style>-->

<style-author>Oscar Levin</style-author>
<date>2025-03-21</date>
Expand Down Expand Up @@ -91,9 +90,7 @@ along with PreTeXt. If not, see <http://www.gnu.org/licenses/>.
<appendices cmd="appendix"/>


<bibliography cmd="bibliography">
<arg><bib-file/></arg>
</bibliography>
<bibliography/>


<end-document/>
Expand Down
Loading