Skip to content
Snippets Groups Projects
Commit a7b66c6e authored by Frank Steinberg's avatar Frank Steinberg
Browse files

First attempts on actual translation.

parent b48ac721
Branches
No related tags found
No related merge requests found
...@@ -15,10 +15,11 @@ orig: bjcp-2015-styleguide-orig.xml xsl/bjcp-2015-styleguide-split.xsl ...@@ -15,10 +15,11 @@ orig: bjcp-2015-styleguide-orig.xml xsl/bjcp-2015-styleguide-split.xsl
if [ ! -d orig ] ; then mkdir orig ; fi if [ ! -d orig ] ; then mkdir orig ; fi
xsltproc xsl/bjcp-2015-styleguide-split.xsl bjcp-2015-styleguide-orig.xml xsltproc xsl/bjcp-2015-styleguide-split.xsl bjcp-2015-styleguide-orig.xml
bjcp-2015-styleguide-de.xml: orig xsl/bjcp-2015-styleguide-translate.xsl bjcp-2015-styleguide-de.xml: orig de xsl/bjcp-2015-styleguide-translate.xsl
xsltproc --stringparam lang de xsl/bjcp-2015-styleguide-translate.xsl bjcp-2015-styleguide-orig.xml > bjcp-2015-styleguide-de.xml xsltproc --stringparam lang de xsl/bjcp-2015-styleguide-translate.xsl bjcp-2015-styleguide-orig.xml > bjcp-2015-styleguide-de.xml
clean: clean:
rm -rf cache orig rm -rf cache orig
rm -f bjcp-2015-styleguide-orig.xml rm -f bjcp-2015-styleguide-orig.xml
rm -f bjcp-2015-styleguide-de.xml
<?xml version="1.0"?> <?xml version="1.0"?>
<styleguide> <styleguide>
<category id="1"> <category id="1">
<name>Standard American Beer</name> <name>Amerikanisches Standard-Bier</name>
<description>This category describes everyday American beers that have a wide public appeal. Containing both ales and lagers, the beers of this category are not typically complex, and have smooth, accessible flavors. The ales tend to have lager-like qualities, or are designed to appeal to mass-market lager drinkers as crossover beers. Mass-market beers with a more international appeal or origin are described in the International Lager category.</description> <description>
<p>Diese Kategorie...</p>
</description>
</category> </category>
</styleguide> </styleguide>
...@@ -2,17 +2,9 @@ ...@@ -2,17 +2,9 @@
<styleguide> <styleguide>
<category id="1"> <category id="1">
<subcategory id="1A"> <subcategory id="1A">
<name>American Light Lager</name> <name>Amerikanisches Light Lager</name>
<overall-impression>Highly carbonated, very light-bodied, nearly flavorless lager designed to be consumed very cold. Very refreshing and thirst quenching.</overall-impression> <overall-impression>Stark karbonisiertes, sehr leichtes, ...</overall-impression>
<aroma>Low to no malt aroma, although it can be perceived as grainy, sweet, or corn-like if present. Hop aroma is light to none, with a spicy or floral hop character if present. While a clean fermentation character is desirable, a light amount of yeast character (particularly a light apple fruitiness) is not a fault. Light DMS is not a fault.</aroma> <!-- ... hier in der Übersetzung nicht erscheinende Elemente werden aus dem Original übernommen. -->
<appearance>Very pale straw to pale yellow color. White, frothy head seldom persists. Very clear.</appearance>
<flavor>Relatively neutral palate with a crisp and dry finish and a low to very low grainy or corn-like flavor that might be perceived as sweetness due to the low bitterness. Hop flavor ranges from none to low levels, and can have a floral, spicy, or herbal quality (although rarely strong enough to detect). Low to very low hop bitterness. Balance may vary from slightly malty to slightly bitter, but is relatively close to even. High levels of carbonation may accentuate the crispness of the dry finish. Clean lager fermentation character.</flavor>
<mouthfeel>Very light (sometimes watery) body. Very highly carbonated with slight carbonic bite on the tongue.</mouthfeel>
<comments>Designed to appeal to as broad a range of the general public as possible. Strong flavors are a fault.</comments>
<history>Coors briefly made a light lager in the early 1940s. Modern versions were first produced by Rheingold in 1967 to appeal to diet-conscious drinkers, but only became popular starting in 1973 after Miller Brewing acquired the recipe and marketed the beer heavily to sports fans with the &#x201C;tastes great, less filling&#x201D; campaign. Beers of this genre became the largest sellers in the United States in the 1990s.</history>
<characteristic-ingredients>Two- or six-row barley with high percentage (up to 40%) of rice or corn as adjuncts. Additional enzymes can further lighten the body and lower carbohydrates.</characteristic-ingredients>
<style-comparison>A lighter-bodied, lower-alcohol, lower calorie version of an American Lager. Less hop character and bitterness than a Leichtbier.</style-comparison>
<commercial-examples>Bud Light, Coors Light, Keystone Light, Michelob Light, Miller Lite, Old Milwaukee Light</commercial-examples>
</subcategory> </subcategory>
</category> </category>
</styleguide> </styleguide>
...@@ -26,6 +26,103 @@ ...@@ -26,6 +26,103 @@
<xsl:template match="category">
<xsl:variable name="d">
<xsl:text>../</xsl:text>
<xsl:value-of select="$lang"/>
<xsl:text>/</xsl:text>
<xsl:value-of select="@id"/>
<xsl:text>.xml</xsl:text>
</xsl:variable>
<xsl:variable name="p">
<xsl:text>document('</xsl:text>
<xsl:value-of select="$d"/>
<xsl:text>')/styleguide/category[@id='</xsl:text>
<xsl:value-of select="@id"/>
<xsl:text>']</xsl:text>
</xsl:variable>
<xsl:element name="{local-name(.)}">
<xsl:apply-templates select="@*"/>
<xsl:apply-templates>
<xsl:with-param name="t" select="$p"/>
</xsl:apply-templates>
</xsl:element>
</xsl:template>
<xsl:template match="category/subcategory">
<xsl:variable name="d">
<xsl:text>../</xsl:text>
<xsl:value-of select="$lang"/>
<xsl:text>/</xsl:text>
<xsl:value-of select="@id"/>
<xsl:text>.xml</xsl:text>
</xsl:variable>
<xsl:variable name="p">
<xsl:text>document('</xsl:text>
<xsl:value-of select="$d"/>
<xsl:text>')/styleguide/category/subcategory[@id='</xsl:text>
<xsl:value-of select="@id"/>
<xsl:text>']</xsl:text>
</xsl:variable>
<xsl:element name="{local-name(.)}">
<xsl:apply-templates select="@*"/>
<xsl:apply-templates>
<xsl:with-param name="t" select="$p"/>
</xsl:apply-templates>
</xsl:element>
</xsl:template>
<xsl:template match="category/subcategory/subcategory">
<xsl:variable name="d">
<xsl:text>../</xsl:text>
<xsl:value-of select="$lang"/>
<xsl:text>/</xsl:text>
<xsl:value-of select="@id"/>
<xsl:text>.xml</xsl:text>
</xsl:variable>
<xsl:variable name="p">
<xsl:text>document('</xsl:text>
<xsl:value-of select="$d"/>
<xsl:text>')/styleguide/category/subcategory/subcategory[@id='</xsl:text>
<xsl:value-of select="@id"/>
<xsl:text>']</xsl:text>
</xsl:variable>
<xsl:element name="{local-name(.)}">
<xsl:apply-templates select="@*"/>
<xsl:apply-templates>
<xsl:with-param name="t" select="$p"/>
</xsl:apply-templates>
</xsl:element>
</xsl:template>
<xsl:template match="name|description|overall-impression|aroma|appearance|flavor|mouthfeel|comments|history|characteristic-ingredients|style-comparison|entry-instructions|commercial-examples">
<xsl:param name="t"/>
<xsl:variable name="p">
<xsl:value-of select="$t"/>
<xsl:text>/</xsl:text>
<xsl:value-of select="local-name(.)"/>
</xsl:variable>
<xsl:element name="{local-name(.)}">
<xsl:apply-templates select="@*"/>
<xsl:choose>
<xsl:when test="dyn:evaluate($p)">
<xsl:apply-templates select="dyn:evaluate($p)/* | dyn:evaluate($p)/text()"/>
</xsl:when>
<xsl:otherwise>
<xsl:apply-templates/>
</xsl:otherwise>
</xsl:choose>
</xsl:element>
</xsl:template>
<xsl:template match="@*"> <xsl:template match="@*">
<xsl:copy> <xsl:copy>
<xsl:apply-templates select="@*"/> <xsl:apply-templates select="@*"/>
...@@ -36,6 +133,10 @@ ...@@ -36,6 +133,10 @@
<xsl:template match="text()"> <xsl:template match="text()">
<xsl:copy>
<xsl:apply-templates/>
</xsl:copy>
<!--
<xsl:variable name="d"> <xsl:variable name="d">
<xsl:value-of select="$lang"/> <xsl:value-of select="$lang"/>
<xsl:text>/</xsl:text> <xsl:text>/</xsl:text>
...@@ -52,6 +153,7 @@ ...@@ -52,6 +153,7 @@
</xsl:copy> </xsl:copy>
</xsl:otherwise> </xsl:otherwise>
</xsl:choose> </xsl:choose>
-->
</xsl:template> </xsl:template>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment