title: How to perform when..else in declarative pipeline
body: <p>I'm using a declarative pipeline. This part works:</p>
  
  <pre><code>        steps {
              script {
                  if ('xxx' == 'cloud') {
                      sh 'xxx'
                  } else {
                      sh 'xxx'
                  }
              }
          }
  </code></pre>
  
  <p>But I want to follow the more declarative pipeline syntax using <a href="https://jenkins.io/doc/book/pipeline/syntax/#when" rel="nofollow noreferrer">when</a>.
      I tried something like this:</p>
  
  <pre><code>        stage ('Newman run') {
              when {
                  expression { "xxx" == "cloud" }
              }
              steps {
                  echo 'Use proxy for cloud'
                  sh 'xx'
              }
              when {
                  expression { "cloud" == "cloud" }
              }
              steps {
                  echo 'Do not use proxy (non-cloud)'
                  sh 'xxx'
              }
  </code></pre>
  
  <p>But it didn't work. How I can specify a sort of '<code>else</code>' statement after a <code>when</code> in a declarative pipeline. Or if this not works, the recommended way to do this?</p>