Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/jenkinsci/labelled-steps-plugin
Replacements for Jenkins pipeline `sh`, `bat`, and `powershell` steps to allow displaying a custom label in the BlueOcean UI.
https://github.com/jenkinsci/labelled-steps-plugin
jenkins jenkins-ci jenkins-pipeline jenkins-pipeline-plugin jenkins-plugin jenkinsfile
Last synced: 3 months ago
JSON representation
Replacements for Jenkins pipeline `sh`, `bat`, and `powershell` steps to allow displaying a custom label in the BlueOcean UI.
- Host: GitHub
- URL: https://github.com/jenkinsci/labelled-steps-plugin
- Owner: jenkinsci
- License: mit
- Created: 2018-08-10T15:43:54.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2024-08-09T10:45:00.000Z (5 months ago)
- Last Synced: 2024-09-30T18:01:31.740Z (3 months ago)
- Topics: jenkins, jenkins-ci, jenkins-pipeline, jenkins-pipeline-plugin, jenkins-plugin, jenkinsfile
- Language: Java
- Homepage: https://plugins.jenkins.io/labelled-steps
- Size: 13.7 KB
- Stars: 9
- Watchers: 3
- Forks: 6
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# labelled-steps-plugin
Currently this plugin provides a replacement for the [`sh`][sh], [`bat`][bat] and [`powershell`][powershell] steps in Jenkins
pipelines to allow displaying a custom label in the BlueOcean UI.### Why is this needed?
See [JENKINS-36933][] and [JENKINS-37324][].
### Example
In the following example, the BlueOcean UI will display `Building the universe from scratch...`
as the step title (the step title is the thing you click on to see the shell output):```groovy
labelledShell label: 'Building the universe from scratch...', script: """
echo "Sparking the Big Bang..."
echo "Cosmic inflation begins..."
# ...
"""
labelledBatch label: 'Building the universe from scratch...', script: """
echo "Sparking the Big Bang..."
echo "Cosmic inflation begins..."
# ...
"""
labelledPowerShell label: 'Building the universe from scratch...', script: """
echo "Sparking the Big Bang..."
echo "Cosmic inflation begins..."
# ...
"""
```[sh]: https://jenkins.io/doc/pipeline/steps/workflow-durable-task-step/#sh-shell-script
[bat]: https://jenkins.io/doc/pipeline/steps/workflow-durable-task-step/#bat-windows-batch-script
[powershell]: https://jenkins.io/doc/pipeline/steps/workflow-durable-task-step/#powershell-powershell-script
[JENKINS-36933]: https://issues.jenkins-ci.org/browse/JENKINS-36933
[JENKINS-37324]: https://issues.jenkins-ci.org/browse/JENKINS-37324