I'm looking to see if it's possible for something like this: How can I define additional parameters in jenkinsfile who inherit from a pipeline shared lib?
But in a declarative pipeline, I've tried solutions similar to that of the post above but with no luck.
I need to be able to declare a shared library of build parameters which I can then use in multiple declared pipelines.
Something like this:
pipeline {
agent {
label 'slave'
}
parameters { // Build parameters
string(defaultValue: 'test', description: 'SCM branch', name: 'UUT_BRANCH', trim: false)
# DEFININED IN SHARED LIBRARY
}
I wondered if anyone could provide any input? Many thanks.