Hi,

      How can I use p4 groovy in declarative pipeline?

      p4karl, you told me that I can use below syntax, but I can't use this.

       

      pipeline {
        agent {
          kubernetes {
           label 'test'
           yamlFile 'test.yaml'
          }
        }
        options {
          skipDefaultCheckout()
        }
        stages {
          stage('Run Test') {
            steps {
              container(name: 'test', shell: '/bin/bash') {
                p4 credential: 'p4_10.251.245.74_1667_perforce', workspace: templateSpec(charset: 'utf8', format: 'jenkins-${JOB_NAME}-${BUILD_ID}-${NODE_NAME}', pinHost: false, templateName: 'TEMPLATE')
                // and how to use p4.run('client', '-o') for example
              }
            }
          }
        }
      }
      

          [JENKINS-58250] how to use p4groovy in declarative pipeline

          Hokwang Lee created issue -
          Karl Wirth made changes -
          Assignee New: Karl Wirth [ p4karl ]
          Karl Wirth made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Resolved [ 5 ]
          Karl Wirth made changes -
          Labels New: P4_SUPPORT
          Karl Wirth made changes -
          Status Original: Resolved [ 5 ] New: Closed [ 6 ]

            p4karl Karl Wirth
            luckyhorang Hokwang Lee
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: