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

Conditional Build Step - Add support for else clause

      It would be nice if the conditional build step allowed for an else block.

      I don't necessarily want support for nesting those blocks, but in the case of boolean conditions, it makes a lot of sense to create an:
      if {

      } else {

      }
      construct in the job.

      I realize I could make two conflicting (if equals and then if not equals) but having the two blocks makes much more sense.

      Especially when users have multi-step builds. For example:

      Multi-Step build:
      1) make clean
      2) if($PROFILING)

      { make -PROFILING=TRUE }

      2) else

      {make -PROFILING=FALSE }

      3) make install
      4) if ($GENERATE_DOCS)

      { ./generateDocs }

      5) `some final step`

          [JENKINS-25918] Conditional Build Step - Add support for else clause

          Sean Grider created issue -
          Dominik Bartholdi made changes -
          Resolution New: Duplicate [ 3 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]
          Dominik Bartholdi made changes -
          Link New: This issue duplicates JENKINS-20292 [ JENKINS-20292 ]

          nisar T added a comment -

          Is the change integrated?. I really need this.

          nisar T added a comment - Is the change integrated?. I really need this.

          no, PullRequests welcome...

          Dominik Bartholdi added a comment - no, PullRequests welcome...
          R. Tyler Croy made changes -
          Workflow Original: JNJira [ 159905 ] New: JNJira + In-Review [ 196238 ]
          Sean Grider made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]

            domi Dominik Bartholdi
            kaibutsux Sean Grider
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: