configure-entries.jelly 8.0 KB
Newer Older
K
kohsuke 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
<!--
The MIT License

Copyright (c) 2004-2009, Sun Microsystems, Inc., Kohsuke Kawaguchi, Seiji Sogabe

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
-->

25 26 27
<!--
  Config page.
-->
28
<?jelly escape-by-default='true'?>
29
<j:jelly xmlns:j="jelly:core" xmlns:st="jelly:stapler" xmlns:d="jelly:define" xmlns:l="/lib/layout" xmlns:t="/lib/hudson" xmlns:f="/lib/form" xmlns:i="jelly:fmt" xmlns:p="/lib/hudson/project">
30 31
  <st:include page="configure-common.jelly" />

32 33 34
  <p:config-trigger>
    <!-- setting to ignore upstream changes is done as a pseudo-trigger -->
    <f:optionalBlock name="maven.triggerByDependency"
35
        help="/plugin/maven-plugin/ignore-upstrem-changes.html"
36
        title="${%Build whenever a SNAPSHOT dependency is built}"
37
        checked="${h.defaultToTrue(!it.ignoreUpstremChanges())}" />
38
    <p:config-upstream-pseudo-trigger />
39
  </p:config-trigger>
40

I
imod 已提交
41 42 43 44 45 46 47 48 49
  <f:section title="${%Pre Steps}">
    <f:block>
      <f:hetero-list name="prebuilder" hasHeader="true"
                     descriptors="${h.getBuilderDescriptors(it)}"
                     items="${it.prebuilders}"
                     addCaption="${%Add pre-build step}"/>
    </f:block>
  </f:section>
  
K
kohsuke 已提交
50
  <f:section title="${%Build}">
51
    <j:set var="mavens" value="${it.descriptor.mavenDescriptor.installations}" />
52 53
    <j:if test="${empty(mavens)}">
      <!-- no maven installation is configured. this will be an error, so warn the user now -->
K
kohsuke 已提交
54
      <f:entry title="${%Maven Version}">
55
        <div class="error">
S
sogabe 已提交
56 57
          ${%Maven Version.error.1}&lt;br>
          ${%Maven Version.error.2(rootURL)}
58
        </div>
59 60
      </f:entry>
    </j:if>
61
    <j:if test="${mavens.size() gt 1}">
62
      <!-- choice not necessary if there's no choice -->
K
kohsuke 已提交
63
      <f:entry title="${%Maven Version}">
64 65 66 67 68 69 70
        <select class="setting-input" name="maven_version">
          <j:forEach var="inst" items="${mavens}">
            <f:option selected="${inst.name==it.maven.name}">${inst.name}</f:option>
          </j:forEach>
        </select>
      </f:entry>
    </j:if>
71
    <f:entry title="${%Root POM}" help="/plugin/maven-plugin/root-pom.html">
K
kohsuke 已提交
72
      <f:textbox name="rootPOM" value="${it.rootPOM}"
73
              checkUrl="'checkFileInWorkspace?value='+escape(this.value)" />
74
    </f:entry>
75
    <f:entry title="${%Goals and options}" help="/plugin/maven-plugin/goals.html">
76 77
      <f:textbox name="goals" value="${it.userConfiguredGoals}"/>
    </f:entry>
78
    <f:advanced>
79
      <f:entry title="MAVEN_OPTS" help="/plugin/maven-plugin/maven-opts.html">
K
kohsuke 已提交
80
        <f:expandableTextbox name="mavenOpts" value="${it.mavenOpts}" />
81
      </f:entry>
82 83 84 85
      <f:entry title="${%Alternate settings file}"
               help="/plugin/maven-plugin/alternate-settings.html">
        <f:textbox name="alternateSettings"
                   value="${it.alternateSettings}" 
86
                   checkUrl="'checkFileRelative?value='+escape(this.value)"
87 88
                   />
      </f:entry>
89 90
      <f:optionalBlock name="maven.incrementalBuild"
                       title="${%Incremental build - only build changed modules}"
91
                       help="/plugin/maven-plugin/incremental.html"
92
                       checked="${it.isIncrementalBuild()}" />
93 94 95 96
      <f:optionalBlock name="maven.archivingDisabled"
                       title="${%Disable automatic artifact archiving}"
                       help="/plugin/maven-plugin/archivingDisabled.html"
                       checked="${it.isArchivingDisabled()}" />
97
      <f:optionalBlock name="maven.perModuleBuild" title="${%Build modules in parallel}" help="/plugin/maven-plugin/aggregator.html"
98
        checked="${!it.aggregatorStyleBuild}" />
99
      <f:optionalBlock name="maven.usePrivateRepository" title="${%Use private Maven repository}" help="/plugin/maven-plugin/private-repository.html"
100
        checked="${it.usesPrivateRepository()}" />
101 102
      <f:optionalBlock name="maven.resolveDependencies" title="${%Resolve Dependencies during Pom parsing}" 
        checked="${it.isResolveDependencies()}" /> 
103 104 105
      <f:optionalBlock name="maven.runHeadless" title="${%Run Headless}" help="/plugin/maven-plugin/run-headless.html"
        checked="${it.runHeadless()}" />
      <f:optionalBlock name="maven.processPlugins" title="${%Process Plugins during Pom parsing}"
106 107
        checked="${it.isProcessPlugins()}" />
      <p:config-customWorkspace />
108 109 110 111 112 113 114 115
        
      <j:set var="mavenValidationLevels" value="${it.descriptor.mavenValidationLevels}" />   
      <f:entry title="${%Maven Validation Level}">
        <select class="setting-input" name="maven.validationLevel">
          <j:forEach var="level" items="${mavenValidationLevels}">
            <f:option selected="${it.mavenValidationLevel == level.value}" value="${level.value}">${level.key}</f:option>
          </j:forEach>
        </select>
116 117 118 119 120
      </f:entry>

      <j:set var="mavenSettingsConfigs" value="${it.allMavenSettingsConfigs}" />
      <f:entry title="${%Maven Settings Configs}">
        <select class="setting-input" name="maven.mavenSettingsConfigId">
I
imod 已提交
121
          <f:option value="">- select -</f:option>
122 123 124 125 126 127
          <j:forEach var="settingConfig" items="${mavenSettingsConfigs}">
            <f:option selected="${it.settingConfigId == settingConfig.id}" value="${settingConfig.id}">${settingConfig.name}</f:option>
          </j:forEach>
        </select>
      </f:entry>

128 129 130 131 132 133 134 135 136 137
      <j:set var="mavenGlobalSettingsConfigs" value="${it.allGlobalMavenSettingsConfigs}" />
      <f:entry title="${%Maven Global Settings Configs}">
        <select class="setting-input" name="maven.mavenGlobalSettingConfigId">
          <f:option value="">- select -</f:option>
          <j:forEach var="globalSettingConfig" items="${mavenGlobalSettingsConfigs}">
            <f:option selected="${it.globalSettingConfigId == globalSettingConfig.id}" value="${globalSettingConfig.id}">${globalSettingConfig.name}</f:option>
          </j:forEach>
        </select>
      </f:entry>

138
    </f:advanced>
139
  </f:section>
140

I
imod 已提交
141
  <f:section title="${%Post Steps}">
K
Kohsuke Kawaguchi 已提交
142 143 144 145 146 147 148
    <f:entry description="${%criteriaDescription}">
      <f:radio name="post-steps.runIfResult" value="success" checked="${instance.runPostStepsIfResult.toString() =='SUCCESS'}" title="${%runIfStable}"/>
      <st:nbsp />
      <f:radio name="post-steps.runIfResult" value="unstable" checked="${instance.runPostStepsIfResult.toString() =='UNSTABLE'}" title="${%runIfSuccessful}"/>
      <st:nbsp />
      <f:radio name="post-steps.runIfResult" value="failure" checked="${instance==null || instance.runPostStepsIfResult.toString() =='FAILURE'}" title="${%runAlways}"/>
    </f:entry>
I
imod 已提交
149 150 151 152 153 154 155 156
    <f:block>
      <f:hetero-list name="postbuilder" hasHeader="true"
                     descriptors="${h.getBuilderDescriptors(it)}"
                     items="${it.postbuilders}"
                     addCaption="${%Add post-build step}"/>
    </f:block>
  </f:section>

157 158
  <j:invokeStatic var="reporters" className="hudson.maven.MavenReporters" method="getConfigurableList" />
  <j:if test="${!empty(reporters)}">
K
kohsuke 已提交
159
    <f:descriptorList title="${%Build Settings}"
160
                      descriptors="${reporters}"
161
                      instances="${it.reporters.toMap()}" />
162
  </j:if>
163

I
imod 已提交
164

K
kohsuke 已提交
165
  <p:config-buildWrappers />
166
  <p:config-publishers />
167
</j:jelly>