How can i use shared library in jenkins for my dsl groovy scripts?
Most of my scripts have same steps except few changes in name and url, i do not want to create new script every time. Is there any way one script and do the job?
How can i use shared library in jenkins for my dsl groovy scripts?
Most of my scripts have same steps except few changes in name and url, i do not want to create new script every time. Is there any way one script and do the job?
Yes, you can create a Jenkins shared library and configure it in Jenkins.
The shared library is a git repository with defined structure where you declare your shared steps and you can include it in each pipeline script with @Library('<library name>')
.