title: Jenkins Scripted Pipeline use global timestamps options
body: <p>In my scripted pipeline I would like to set global <code>timestamps</code> and <code>ansicolor</code> option. </p>
  
  <p>Below scripted pipeline not working. How can we add these two options in scripted pipeline?</p>
  
  <p><strong>Declarative Pipeline</strong></p>
  
  <pre><code>pipeline {
    agent none
    options {
      timestamps()
      ansiColor('xterm')  
    }
  
    stages {    
      stage('Checkout') {
        agent { label 'linux' }
        steps{
        echo "test"
        }
      }
    }
  }
  </code></pre>
  
  <p><strong>Scripted Pipeline</strong></p>
  
  <pre><code>node('linux') {
  options {
      timestamps()
      ansiColor('xterm')
  
    }  
      stage('Pre Build Setup') {
          task('Display env') {
          echo "test"
          }
      }
  }
  </code></pre>