Blinky american physical society style

Sharing the american physical society csl for use with the blinky package. This will link.color the bibliography as is done in the APS journals:

<?xml version="1.0" encoding="utf-8"?>
<style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0" demote-non-dropping-particle="sort-only" default-locale="en-US">
  <info>
    <title>American Physical Society</title>
    <title-short>APS</title-short>
    <id>http://www.zotero.org/styles/american-physics-society</id>
    <link href="http://www.zotero.org/styles/american-physics-society" rel="self"/>
    <link href="http://www.zotero.org/styles/american-institute-of-physics" rel="template"/>
    <link href="https://journals.aps.org/prl/authors#techformat" rel="documentation"/>
    <author>
      <name>Richard Karnesky</name>
      <email>karnesky+zotero@gmail.com</email>
      <uri>http://arc.nucapt.northwestern.edu/Richard_Karnesky</uri>
    </author>
    <author>
      <name>Brenton M. Wiernik</name>
    </author>
    <contributor>
      <name>Anna C. Véron</name>
    </contributor>
    <category citation-format="numeric"/>
    <category field="physics"/>
    <summary>Common style use by APS publications.</summary>
    <updated>2024-12-17T11:58:54+00:00</updated>
    <rights license="http://creativecommons.org/licenses/by-sa/3.0/">This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 License</rights>
  </info>
  <macro name="author">
    <names variable="author">
      <name and="text" et-al-min="11" et-al-use-first="1" initialize-with=". " delimiter=", "/>
      <label form="long" prefix=", " suffix=" "/>
      <substitute>
        <names variable="editor"/>
        <names variable="translator"/>
      </substitute>
    </names>
  </macro>
  <macro name="editor">
    <names variable="editor">
      <label form="verb" suffix=" "/>
      <name delimiter=", " initialize-with=". " and="text"/>
    </names>
  </macro>
  <macro name="year-date">
    <choose>
      <if variable="issued">
        <date variable="issued">
          <date-part name="year"/>
        </date>
      </if>
      <else>
        <text term="no date" form="short"/>
      </else>
    </choose>
  </macro>
  <macro name="day-date">
    <choose>
      <if variable="issued">
        <date variable="issued">
          <date-part name="day" suffix=" "/>
          <date-part name="month" form="long" suffix=" "/>
          <date-part name="year"/>
        </date>
      </if>
      <else>
        <text term="no date" form="short"/>
      </else>
    </choose>
  </macro>
  <macro name="publisher">
    <group prefix="(" suffix=")" delimiter=", ">
      <text variable="publisher"/>
      <text variable="publisher-place" text-case="title"/>
      <text macro="year-date"/>
    </group>
  </macro>
  <macro name="edition-volume">
    <group delimiter=", ">
      <choose>
        <if is-numeric="edition">
          <group delimiter=" ">
            <number variable="edition" form="ordinal"/>
            <text term="edition" form="short"/>
          </group>
        </if>
        <else>
          <text variable="edition"/>
        </else>
      </choose>
      <group delimiter=" ">
        <label variable="volume" form="short" text-case="capitalize-first"/>
        <text variable="volume"/>
      </group>
    </group>
  </macro>

  <macro name="blinky-link-open">
    <choose>
      <if variable="DOI">
        <text variable="DOI" prefix="<<<https://doi.org/" suffix="|||"/>
      </if>
      <else-if variable="URL">
        <text variable="URL" prefix="<<<" suffix="|||"/>
      </else-if>
    </choose>
  </macro>

  <macro name="blinky-link-close">
    <choose>
      <if variable="DOI URL" match="any">
        <text value=">>>"/>
      </if>
    </choose>
  </macro>

  <macro name="blinky-title">
    <text variable="title" text-case="title"/>
  </macro>
  <citation collapse="citation-number">
    <sort>
      <key variable="citation-number"/>
    </sort>
    <layout delimiter="," prefix="&#160;[" suffix="]">
      <text variable="citation-number"/>
    </layout>
  </citation>
  <bibliography entry-spacing="0" second-field-align="flush">
    <!-- Reference for book, chapter, report layouts: https://doi.org/10.1103/PhysRevX.10.011010 -->
    <!-- Reference for arXiv: https://doi.org/10.1103/PhysRevX.10.011004 -->
    <layout suffix=".">
      <text variable="citation-number" prefix="[" suffix="]"/>
      <text macro="author" suffix=", "/>
      <choose>
        <if type="bill book figure graphic legal_case legislation map motion_picture song treaty" match="any">
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <group delimiter=" ">
                <text macro="edition-volume"/>
                <text macro="publisher"/>
              </group>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </if>
        <else-if type="broadcast chapter entry entry-dictionary entry-encyclopedia paper-conference" match="any">
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <group delimiter=" ">
                <text term="in"/>
                <group delimiter=", ">
                  <text variable="container-title" text-case="title"/>
                  <text macro="editor"/>
                  <text macro="edition-volume"/>
                </group>
                <group delimiter=", ">
                  <text macro="publisher"/>
                  <group delimiter=" ">
                    <label variable="page" form="short"/>
                    <text variable="page"/>
                  </group>
                </group>
              </group>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </else-if>
        <else-if type="patent">
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <group delimiter=" ">
                <text variable="number"/>
                <text macro="day-date" prefix="(" suffix=")"/>
              </group>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </else-if>
        <else-if type="thesis report" match="any">
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <group delimiter=", ">
                <group delimiter=" ">
                  <text variable="genre"/>
                  <group delimiter=" ">
                    <text term="issue" form="short" text-case="capitalize-first"/>
                    <text variable="number"/>
                  </group>
                </group>
                <text variable="publisher"/>
                <text macro="year-date"/>
              </group>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </else-if>
        <else-if type="article" match="any">
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <choose>
                <if variable="container-title">
                  <text variable="container-title"/>
                </if>
                <else>
                  <text variable="number"/>
                </else>
              </choose>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </else-if>
        <else-if type="dataset interview manuscript pamphlet personal_communication post post-weblog speech webpage" match="any">
          <!-- unpublished materials; guidelines call for 'enough information to be retrievable' -->
          <!-- Based on arXiv format -->
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <choose>
                <if variable="DOI">
                  <text variable="DOI" prefix="https://doi.org/"/>
                </if>
                <else-if variable="URL">
                  <text variable="URL"/>
                </else-if>
                <else>
                  <text value="(unpublished)"/>
                </else>
              </choose>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </else-if>
        <else>
          <!--article-journal article-magazine article-newspaper review review-book-->
          <group delimiter=", ">
            <text macro="blinky-title"/>
            <group>
              <text macro="blinky-link-open"/>
              <group delimiter=" ">
                <text variable="container-title" form="short" text-case="title"/>
                <group delimiter=", ">
                  <text variable="volume"/>
                  <group delimiter=" ">
                    <choose>
                      <if variable="number">
                        <text variable="number"/>
                      </if>
                      <else>
                        <text variable="page-first" form="short"/>
                      </else>
                    </choose>
                    <text macro="year-date" prefix="(" suffix=")"/>
                  </group>
                </group>
              </group>
              <text macro="blinky-link-close"/>
            </group>
          </group>
        </else>
      </choose>
    </layout>
  </bibliography>
</style>

@akoller Not sure if you have archive somewhere to save and update these examples? Maybe a discussion page on github?

3 Likes