How to compile Jenkins Pipeline Groovy locally?

Viewed 3442

Does anyone have the magic maven/gradle invocation to compile a set of jenkins pipeline DSL groovy files?

1 Answers

Groovy is not compiled (like C#), it is interpreted.

Depending on exactly what you are trying to test potential options are:

  1. Jenkins Groovy Script Console under Manage Jenkins. Note: You will need to be an Admin to be able to access this.
  2. Pipeline Syntax Generator. It is improving. Go to a build of Pipeline job and in the LHS menu you will see a 'Pipeline Syntax' link. Some items require you to first select Pipeline: Steps from the first dropdown.
Related