Details
-
Type:
Story
-
Status: Closed (View Workflow)
-
Priority:
Minor
-
Resolution: Fixed
-
Component/s: badge-plugin, groovy-postbuild-plugin
-
Labels:None
-
Similar Issues:
Description
Is there a way to add a groovy postbuild step in a declarative pipeline template for creating jobs?
The documentation at https://jenkins.io/doc/pipeline/steps/ doesn't have any references to this plugin so I assume the answer is no, but just wondered if there might be another workaround?
Yeah this is a bit confusing. I'd like the ability to do like manager.addShortText(textToDisplay) from a Pipeline Groovy script. It's a bit confusing because this plugin seems to be doing two things, really – its name is deceptive. It provides a way to run Groovy scripts at the end of a build, but it also provides some helpful UI widgets.
This is how the plugin gets its manager – with the right imports you might be able to get it to work in a Pipeline script:
See WorkflowManager.java