Science Score: 31.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Unable to calculate vocabulary similarity
Last synced: 10 months ago · JSON representation ·

Repository

Basic Info
  • Host: GitHub
  • Owner: pulibrary
  • Language: XSLT
  • Default Branch: main
  • Size: 391 KB
Statistics
  • Stars: 0
  • Watchers: 9
  • Forks: 0
  • Open Issues: 2
  • Releases: 0
Created over 10 years ago · Last pushed about 4 years ago
Metadata Files
Readme Citation

README.md

CPANDA Citations

C-:panda_face:

Cleaned up XML + Transform to JSON

Owner

  • Name: Princeton University Library
  • Login: pulibrary
  • Kind: organization
  • Location: Princeton, New Jersey

Citation (citation_to_json.xsl)

<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:local="http://whatever" xmlns:xs="http://www.w3.org/2001/XMLSchema" version="2.0">

  <xsl:output method="text"/>

  <xsl:template match="/">
    <xsl:text>[</xsl:text>
    <xsl:apply-templates/>
    <xsl:text>]</xsl:text>
  </xsl:template>

  <xsl:template match="*" priority="1">
    <xsl:next-match/>
    <xsl:if test="following-sibling::*">,</xsl:if>
  </xsl:template>

  <!-- work is the primary object -->
    <xsl:template match="work">
    <xsl:text>{</xsl:text>
    <xsl:apply-templates/>
    <xsl:text>}</xsl:text>
  </xsl:template>
  
  <!-- numbers -->
  <xsl:template match="id">
    <xsl:value-of select="concat(local:keyify(local-name()), current())"/>
  </xsl:template>
  
  <!-- arrays -->
  <xsl:template match="authors|editors|keywords">
    <xsl:value-of select="concat(local:keyify(local-name()), ' [')"/>
    <xsl:apply-templates/>
    <xsl:text>]</xsl:text>
  </xsl:template>

  <!-- strings that go in arrays -->
  <xsl:template match="name|word">
    <xsl:value-of select="local:quote(.)"/>
  </xsl:template>
  
  <!-- simple "key" : "values" -->
  <xsl:template match="title|edition|language|publisher|date|pages|url|enum|snum|no|name[parent::container]">
    <xsl:value-of select="concat(local:keyify(local-name()), local:quote(.))"/>
  </xsl:template>

  <xsl:template match="@type">
    <xsl:value-of select="concat(local:keyify('type'), '&quot;', current(), '&quot;,')"/>
  </xsl:template>

  <!-- objects { } -->
  <xsl:template match="physicalObject|container">
    <xsl:value-of select="concat(local:keyify(local-name()), ' {')"/>
    <xsl:apply-templates select="*|@type"/>
    <xsl:text>}</xsl:text>
  </xsl:template>
  
  <!-- helpers -->  
  <xsl:function name="local:keyify" as="xs:string">
    <xsl:param name="key-name" as="xs:string"/>
    <xsl:value-of select="concat(local:quote($key-name), ': ')"/>
  </xsl:function> 

  <xsl:function name="local:quote" as="xs:string">
    <xsl:param name="val" as="xs:string"/>
    <xsl:value-of select="concat('&quot;', normalize-space(local:escape-quotes($val)), '&quot;')"/>
  </xsl:function>

  <xsl:function name="local:escape-quotes" as="xs:string">
    <xsl:param name="val" as="xs:string"/>
    <xsl:value-of select="replace($val, '&quot;', '\\&quot;')"/>
  </xsl:function>

</xsl:stylesheet>

GitHub Events

Total
Last Year

Issues and Pull Requests

Last synced: about 1 year ago

All Time
  • Total issues: 2
  • Total pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Total issue authors: 2
  • Total pull request authors: 0
  • Average comments per issue: 0.0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • huvanile (1)
  • kelynch (1)
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels