0

I am using the following groovy script to create a Job DSL that uses Accurev as SCM.
Please let me know how should the correct script look like.

job('payer-server') {
  scm {
    accurev {
      /**What to insert here **/
    }
  }
  triggers {
    scm('H/15 * * * *')
  }
  steps {
    maven {
      goals('-e clean install')
      mavenOpts('-Xms256m')
      mavenOpts('-Xmx512m')
      properties skipTests: true
      mavenInstallation('Maven 3.3.3')
    }
  }
}
meallhour
  • 13,921
  • 21
  • 60
  • 117

1 Answers1

1

Currently there is no built-in support for Accurev SCM. Someone already filed a feature request as JENKINS-22138.

But you can use a Configure Block to generate the necessary config XML. There is an example for configuring Subversion, which can be adapted to Accurev.

job('example') {
    configure { project ->
        project.remove(project / scm) // remove the existing 'scm' element
        project / scm(class: 'hudson.plugins.accurev.AccurevSCM') {
            serverName('foo')
            // ...
        }
    }
    triggers {
        // ...
    }
    steps { 
        // ...
    }
}

Please leave a comment on the feature request to describe which options of Accurev SCM you need to configure initially.

daspilker
  • 8,154
  • 1
  • 35
  • 49