Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-21662

Parameterized Build - List Subversion tags - Use single entry results as default value when no value selected

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • subversion-plugin
    • None

      When having automated builds on the latest svn branches (for a TEST environment - DTAP cycle) with maximum one tag (branch) shown, and no default value given, use the only available tag for builds triggered automatically (not using build with parameters jenkins UI functionality).

      Update the getDefaultParameterValue method in the ListSubversionTagsParameterDefinition class.

      public ParameterValue getDefaultParameterValue() {
      if (StringUtils.isEmpty(this.defaultValue)) {
      List<String> tags = getTags();
      if (tags.size() != 1)

      { return null; }

      else

      { return new ListSubversionTagsParameterValue(getName(), getTagsDir(), tags.get(0)); }

      }
      return new ListSubversionTagsParameterValue(getName(), getTagsDir(), this.defaultValue);
      }

          [JENKINS-21662] Parameterized Build - List Subversion tags - Use single entry results as default value when no value selected

          There are no comments yet on this issue.

            Unassigned Unassigned
            ndgrprov Nico De Groote
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: