Remove unnecessary dependencies for m1.0 compatibility.
If maven.xdoc.locale.default is not defined, use "en" as default. git-svn-id: https://svn.apache.org/repos/asf/maven/maven-1/plugins/trunk@355164 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
5810adfd72
commit
06fe726cf7
@ -33,12 +33,6 @@
|
|||||||
xmlns:define="jelly:define"
|
xmlns:define="jelly:define"
|
||||||
xmlns:checkstyle="checkstyle">
|
xmlns:checkstyle="checkstyle">
|
||||||
|
|
||||||
<j:if test="${bootstrapping == null}">
|
|
||||||
<!-- fake test because the assert:assertPluginAvailable tag is avalaible in the maven-plugin-plugin 1.7 and newer. Thus maven will break if it's not present. -->
|
|
||||||
<assert:assertPluginAvailable groupId="maven" artifactId="maven-plugin-plugin" minRelease="1.7" neededBy="${plugin.artifactId}"/>
|
|
||||||
<assert:assertPluginAvailable groupId="maven" artifactId="maven-xdoc-plugin" minRelease="1.10" neededBy="${plugin.artifactId}"/>
|
|
||||||
</j:if>
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ======================================================================== -->
|
<!-- ======================================================================== -->
|
||||||
|
|
||||||
@ -141,16 +135,23 @@
|
|||||||
file="${maven.checkstyle.cache.file}"/>
|
file="${maven.checkstyle.cache.file}"/>
|
||||||
<ant:mkdir dir="${maven.checkstyle.cache.dir}"/>
|
<ant:mkdir dir="${maven.checkstyle.cache.dir}"/>
|
||||||
|
|
||||||
|
<j:set var="localeCountry" value="en"/>
|
||||||
|
<!-- maven.xdoc.locale.default is only defined in xdoc-plugin >= 1.10 -->
|
||||||
<maven:get var="currentLocale" plugin="maven-xdoc-plugin" property="maven.xdoc.locale.default"/>
|
<maven:get var="currentLocale" plugin="maven-xdoc-plugin" property="maven.xdoc.locale.default"/>
|
||||||
<!-- Extract localeCountry -->
|
<!-- Set localeCountry to maven.xdoc.locale.default, if defined-->
|
||||||
|
<j:choose>
|
||||||
|
<j:when test="${!empty(currentLocale)}">
|
||||||
<j:choose>
|
<j:choose>
|
||||||
<j:when test="${currentLocale.length() >= 2}">
|
<j:when test="${currentLocale.length() >= 2}">
|
||||||
<j:set var="localeCountry" value="${currentLocale.substring(0,2)}"/>
|
<j:set var="localeCountry" value="${currentLocale.substring(0,2)}"/>
|
||||||
</j:when>
|
</j:when>
|
||||||
<j:otherwise>
|
<j:otherwise>
|
||||||
<echo>The locale defined in maven.xdoc.locale.default is invalid.</echo>
|
<echo>The locale defined in maven.xdoc.locale.default is invalid, using "en" instead.</echo>
|
||||||
<echo>As Country code we'll use EN instead.</echo>
|
</j:otherwise>
|
||||||
<j:set var="localeCountry" value="EN"/>
|
</j:choose>
|
||||||
|
</j:when>
|
||||||
|
<j:otherwise>
|
||||||
|
<echo>No locale defined in maven.xdoc.locale.default, using "en".</echo>
|
||||||
</j:otherwise>
|
</j:otherwise>
|
||||||
</j:choose>
|
</j:choose>
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user