Skip to content

Instantly share code, notes, and snippets.

@abayer
Created January 31, 2017 22:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abayer/804cb7ab9a251c43481a720ab215c99e to your computer and use it in GitHub Desktop.
Save abayer/804cb7ab9a251c43481a720ab215c99e to your computer and use it in GitHub Desktop.
What can go in Declarative Pipeline options directive:
* `JobProperty`s that have a `@Symbol` annotation (other than `pipelineTriggers` and `parameters`), i.e.,
* `buildDiscarder`
* `disableConcurrentBuilds`
* ...that may be it currently.
* `DeclarativeOption`s - currently there's literally only one of them, `skipDefaultCheckout()`
* block-scoped `Step`s that don't require a node context - i.e., "wrappers", specified without the closure block:
* `timeout(time: 5, unit: 'MINUTE')`
* `retry(5)`
* `timestamps()`
* `catchError()`
* Literally anything else that is block-scoped but doesn't need to run in a node block.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment