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

Add equals when condition

    XMLWordPrintable

Details

    Description

      I'm trying to think of uses for when expression that I can kill off (death to Scripted and all that), and the most common I've seen is something like foo == 'bar' - i.e., comparing a variable and a value. So let's add a new when condition, tentatively named equals, that does that.

      Attachments

        Activity

          bitwiseman Liam Newman added a comment -

          Bulk closing resolved issues.

          bitwiseman Liam Newman added a comment - Bulk closing resolved issues.

          Code changed in jenkins
          User: Liam Newman
          Path:
          content/doc/book/pipeline/syntax.adoc
          http://jenkins-ci.org/commit/jenkins.io/4e5266831a463049a3d7532ad8c8aacda33cd115
          Log:
          Merge pull request #1425 from abayer/jenkins-49226

          JENKINS-49226 Documentation for new equals condition

          Compare: https://github.com/jenkins-infra/jenkins.io/compare/4381e1845bd6...4e5266831a46

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Liam Newman Path: content/doc/book/pipeline/syntax.adoc http://jenkins-ci.org/commit/jenkins.io/4e5266831a463049a3d7532ad8c8aacda33cd115 Log: Merge pull request #1425 from abayer/jenkins-49226 JENKINS-49226 Documentation for new equals condition Compare: https://github.com/jenkins-infra/jenkins.io/compare/4381e1845bd6...4e5266831a46

          Code changed in jenkins
          User: Andrew Bayer
          Path:
          content/doc/book/pipeline/syntax.adoc
          http://jenkins-ci.org/commit/jenkins.io/60f9e48f7c4178711cc6f9e16628c1391e8a69ab
          Log:
          JENKINS-49226 Documentation for new equals condition

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: content/doc/book/pipeline/syntax.adoc http://jenkins-ci.org/commit/jenkins.io/60f9e48f7c4178711cc6f9e16628c1391e8a69ab Log: JENKINS-49226 Documentation for new equals condition
          abayer Andrew Bayer added a comment -

          This'll be in the upcoming Declarative 1.2.8 release.

          abayer Andrew Bayer added a comment - This'll be in the upcoming Declarative 1.2.8 release.

          Code changed in jenkins
          User: Andrew Bayer
          Path:
          pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional.java
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-actual.html
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-expected.html
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help.html
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditionalScript.groovy
          pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AbstractModelDefTest.java
          pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java
          pipeline-model-definition/src/test/resources/when/whenEquals.groovy
          http://jenkins-ci.org/commit/pipeline-model-definition-plugin/a85f7c50434d187bf5d70e91e88c36ac2a9efa3f
          Log:
          Merge pull request #243 from abayer/jenkins-49226

          [FIXED JENKINS-49226] Add equals condition.

          Compare: https://github.com/jenkinsci/pipeline-model-definition-plugin/compare/6cd7cb80203b...a85f7c50434d

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional.java pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-actual.html pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-expected.html pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help.html pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditionalScript.groovy pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/AbstractModelDefTest.java pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java pipeline-model-definition/src/test/resources/when/whenEquals.groovy http://jenkins-ci.org/commit/pipeline-model-definition-plugin/a85f7c50434d187bf5d70e91e88c36ac2a9efa3f Log: Merge pull request #243 from abayer/jenkins-49226 [FIXED JENKINS-49226] Add equals condition. Compare: https://github.com/jenkinsci/pipeline-model-definition-plugin/compare/6cd7cb80203b...a85f7c50434d

          Code changed in jenkins
          User: Andrew Bayer
          Path:
          pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional.java
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-actual.html
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-expected.html
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help.html
          pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditionalScript.groovy
          pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java
          pipeline-model-definition/src/test/resources/when/whenEquals.groovy
          http://jenkins-ci.org/commit/pipeline-model-definition-plugin/758b597b5adfbc1eeab7032ea0073cbe041ccd71
          Log:
          [FIXED JENKINS-49226] Add equals condition.

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Andrew Bayer Path: pipeline-model-definition/src/main/java/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional.java pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-actual.html pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help-expected.html pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditional/help.html pipeline-model-definition/src/main/resources/org/jenkinsci/plugins/pipeline/modeldefinition/when/impl/EqualsConditionalScript.groovy pipeline-model-definition/src/test/java/org/jenkinsci/plugins/pipeline/modeldefinition/WhenStageTest.java pipeline-model-definition/src/test/resources/when/whenEquals.groovy http://jenkins-ci.org/commit/pipeline-model-definition-plugin/758b597b5adfbc1eeab7032ea0073cbe041ccd71 Log: [FIXED JENKINS-49226] Add equals condition.

          People

            abayer Andrew Bayer
            abayer Andrew Bayer
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: