Merge branch 'master' of ssh://git.indexdata.com/home/git/pub/pazpar2
authorJakub Skoczen <jakub@indexdata.dk>
Fri, 17 Apr 2015 11:22:09 +0000 (13:22 +0200)
committerJakub Skoczen <jakub@indexdata.dk>
Fri, 17 Apr 2015 11:22:09 +0000 (13:22 +0200)
IDMETA
NEWS
etc/xsl/cf.xsl
etc/xsl/solr-pz2.xsl
win/makefile

diff --git a/IDMETA b/IDMETA
index 8e7ad7a..3629e53 100644 (file)
--- a/IDMETA
+++ b/IDMETA
@@ -1,4 +1,4 @@
 DEBIAN_DIST="jessie wheezy squeeze"
 UBUNTU_DIST="utopic trusty saucy precise"
 CENTOS_DIST="centos5 centos6"
-VERSION=1.8.6
+VERSION=1.8.7
diff --git a/NEWS b/NEWS
index 084446b..00965f3 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,15 @@
+--- 1.8.7 2015/03/27
+
+solr-pz2.xsl: extend Solr transformation to emit license_name field PAZ-996
+
+cf.xsl: forwards flat affiliation structure PAZ-992
+
+parpar2: log YAZ version upon start PAZ-993
+
+Update and fix documentation for preferred targets
+
+Fix spelling of present_chunk in documentation
+
 --- 1.8.6 2015/02/10
 
 Increase facet limit PAZ-990
index fdf3edd..794454c 100644 (file)
     </pz:metadata>
   </xsl:template>
 
+  <xsl:template match="affiliation">
+    <pz:metadata type="affiliation-person" empty="PAZPAR2_NULL_VALUE">
+      <xsl:value-of select="person"/>
+    </pz:metadata>
+    <pz:metadata type="affiliation-institution" empty="PAZPAR2_NULL_VALUE">
+      <xsl:value-of select="institution"/>
+    </pz:metadata>
+  </xsl:template>
+
   <xsl:template match="*" >
     <pz:metadata type="{local-name()}">
       <xsl:value-of select="."/>
index 5a11a53..2c5edf3 100644 (file)
          </xsl:attribute>
          <xsl:value-of select="."/>
        </pz:metadata>
+       <xsl:if test="../@name='license_url'">
+        <pz:metadata type="license_name">
+         <xsl:choose>
+          <!-- Creative Commons licenses -->
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by/')">
+           CC By
+          </xsl:when>
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by-sa/')">
+           CC By-SA
+          </xsl:when>
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by-nd/')">
+           CC By-ND
+          </xsl:when>
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by-nc/')">
+           CC By-NC
+          </xsl:when>
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by-nc-sa/')">
+           CC By-NC-SA
+          </xsl:when>
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by-nc-nd/')">
+           CC By-NC-ND
+          </xsl:when>
+
+          <!-- There is actually no such license as this, but East London uses it anyway! -->
+          <xsl:when test="starts-with(., 'http://creativecommons.org/licenses/by-nd-sa/')">
+           CC By-ND-SA
+          </xsl:when>
+
+          <!-- Creative Commons' public-domain tools are not actually licences, may well be used -->
+          <xsl:when test=". = 'http://creativecommons.org/about/cc0'">
+           CC0 (public domain)
+          </xsl:when>
+          <xsl:when test=". = 'http://creativecommons.org/about/pdm2'">
+           CC PDL (public domain)
+          </xsl:when>
+          <!-- The RIOXX profile itself provides two ways of saying "all rights reserved" -->
+          <xsl:when test=". = 'http://www.rioxx.net/licenses/all-rights-reserved'">
+           All rights reserved
+          </xsl:when>
+          <xsl:when test=". = 'http://www.rioxx.net/licenses/under-embargo-all-rights-reserved'">
+           Under embargo
+          </xsl:when>
+
+          <xsl:otherwise>
+           [unknown]
+          </xsl:otherwise>
+         </xsl:choose>
+        </pz:metadata>
+       </xsl:if>
       </xsl:otherwise>
     </xsl:choose>
   </xsl:template>
index a9634cf..3d59581 100644 (file)
@@ -5,7 +5,7 @@
 DEBUG=0   # 0 for release, 1 for debug
 USE_MANIFEST = 0 # Can be enabled Visual Studio 2005/2008
 PACKAGE_NAME=pazpar2
-PACKAGE_VERSION=1.8.6
+PACKAGE_VERSION=1.8.7
 
 # YAZ
 YAZ_DIR=..\..\yaz