This file is indexed.

/usr/share/tellico/musicbrainz2tellico.xsl is in tellico-data 3.1.2-0.1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
<?xml version="1.0"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
                xmlns="http://periapsis.org/tellico/"
                xmlns:str="http://exslt.org/strings"
                xmlns:mb="http://musicbrainz.org/ns/mmd-2.0#"
                exclude-result-prefixes="mb"
                extension-element-prefixes="str"
                version="1.0">

<!--
   ===================================================================
   Tellico XSLT file - used for importing musicbrainz data, version 2

   Copyright (C) 2009-2018 Robby Stephenson -robby@periapsis.org

   This XSLT stylesheet is designed to be used with the 'Tellico'
   application, which can be found at http://tellico-project.org

   ===================================================================
-->

<xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"
            doctype-public="-//Robby Stephenson/DTD Tellico V11.0//EN"
            doctype-system="http://periapsis.org/tellico/dtd/v11/tellico.dtd"/>

<xsl:template match="/">
 <tellico syntaxVersion="11">
  <collection title="Search Results" type="4"> <!-- 4 is music -->
   <fields>
    <field name="_default"/>
    <field flags="0" title="MusicBrainz ID" category="General" format="4" type="1" name="mbid"/>
   </fields>
   <xsl:apply-templates select="//mb:release"/>
  </collection>
 </tellico>
</xsl:template>

<xsl:template match="mb:release">
 <entry>
  <title>
   <xsl:value-of select="mb:title"/>
  </title>

  <mbid>
   <xsl:value-of select="@id"/>
  </mbid>

  <year>
   <xsl:value-of select="substring(mb:release-event-list/mb:release-event[1]/mb:date, 1, 4)"/>
  </year>

  <artists>
   <xsl:for-each select="mb:artist-credit/mb:name-credit">
    <artist>
     <xsl:value-of select="mb:artist/mb:name"/>
    </artist>
   </xsl:for-each>
  </artists>

  <labels>
   <xsl:for-each select="mb:label-info-list/mb:label-info">
    <label>
     <xsl:value-of select="mb:label/mb:name"/>
    </label>
   </xsl:for-each>
  </labels>

  <xsl:if test="mb:medium-list/mb:medium[1]/mb:format = 'CD'">
   <medium i18n='yes'>Compact Disc</medium>
  </xsl:if>
  <xsl:if test="mb:medium-list/mb:medium[1]/mb:format = 'Cassette'">
   <medium i18n='yes'>Cassette</medium>
  </xsl:if>
  <xsl:if test="mb:medium-list/mb:medium[1]/mb:format = 'Vinyl'">
   <medium i18n='yes'>Vinyl</medium>
  </xsl:if>

  <genres>
   <xsl:if test="contains(mb:release-group/@type,'oundtrack')">
    <genre i18n='yes'>Soundtrack</genre>
   </xsl:if>
  </genres>

  <!-- tags are too random, don't use them -->
  <!--
  <keywords>
   <xsl:for-each select="mb:tag-list/mb:tag">
    <keyword>
     <xsl:value-of select="."/>
    </keyword>
   </xsl:for-each>
  </keywords>
  -->

  <xsl:variable name="release" select="."/>
  <tracks>
   <xsl:for-each select="mb:medium-list/mb:medium/mb:track-list/mb:track">
    <track>
     <column>
      <xsl:value-of select="mb:recording/mb:title"/>
     </column>
     <column>
     <xsl:choose>
      <xsl:when test="mb:recording/mb:artist">
       <!-- some combinationss are separated by &,but some artists use & -->
       <!-- some combinations uses 'and' -->
       <!-- no way to accurately split, just setlle on comma for now -->
       <xsl:value-of select="translate(mb:recording/mb:artist/mb:name,',', ';')"/>
      </xsl:when>
      <xsl:otherwise>
       <xsl:value-of select="$release/mb:artist-credit/mb:name-credit/mb:artist[1]/mb:name"/>
      </xsl:otherwise>
     </xsl:choose>
     </column>
     <column>
     <xsl:call-template name="time">
      <xsl:with-param name="duration" select="mb:length"/>
     </xsl:call-template>
     </column>
    </track>
   </xsl:for-each>
  </tracks>

  <cover>
   <xsl:choose>
    <xsl:when test="mb:cover-art-archive/mb:front='true'">
     <xsl:value-of select="concat('http://coverartarchive.org/release/',@id,'/front')"/>
    </xsl:when>
    <xsl:when test="mb:relation-list[@target-type='Url']/mb:relation[@type='CoverArtLink']">
     <xsl:value-of select="mb:relation-list[@target-type='Url']/mb:relation[@type='CoverArtLink'][1]/@target"/>
    </xsl:when>
    <!-- most musicbrainz items have Amazon ASIN values, but not all point got valid images
         if the AmazonAsin Url is set, then it likely does -->
    <xsl:when test="mb:relation-list[@target-type='url']/mb:relation[@type='amazon asin'] and mb:asin">
     <xsl:value-of select="concat('http://ecx.images-amazon.com/images/P/',mb:asin,'.01.MZZZZZZZ.jpg')"/>
    </xsl:when>
   </xsl:choose>
  </cover>

 </entry>
</xsl:template>

<xsl:template name="time">
 <xsl:param name="duration"/>
 <!-- musicbrainz uses milliseconds -->
 <xsl:value-of select="floor($duration div 1000 div 60)"/>
 <xsl:text>:</xsl:text>
 <xsl:value-of select="format-number(($duration div 1000) mod 60,'00')"/>
</xsl:template>

</xsl:stylesheet>