Use build parameter as combinations filter in matrix configuration

1,116 views
Skip to first unread message

Raphau Nowak

unread,
Apr 28, 2013, 12:06:58 PM4/28/13
to jenkins...@googlegroups.com
Hello,
I want to use the parameters I have passed at the beginning of the build on the combined filter. My parameter is a simple choice like:
projectname
- project1
- project2
- project3

I try use this in combination filter like
label==$projectname
label=="$projectname"
label==${projectname}
label=="${projectname}"

but nothing works, i get only a failure if i try to save the config... -.-

Exception: groovy.lang.MissingPropertyException: No such property: $projectname for class: Script1
Stacktrace:
javax.servlet.ServletException: groovy.lang.MissingPropertyException: No such property: $projectname for class: Script1
	at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:719)
	at org.kohsuke.stapler.Stapler.invoke(Stapler.java:770)
	at org.kohsuke.stapler.MetaClass$6.doDispatch(MetaClass.java:241)
	at org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
	at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:677)
	at org.kohsuke.stapler.Stapler.invoke(Stapler.java:770)
	at org.kohsuke.stapler.Stapler.invoke(Stapler.java:583)
	at org.kohsuke.stapler.Stapler.service(Stapler.java:214)
...

any ideas?

oliver gondža

unread,
Apr 28, 2013, 12:48:20 PM4/28/13
to jenkins...@googlegroups.com
Hi,

pull request 584 [1] adds this functionality. You can +1 the Jira or the
pull request to drag more attention.

[1] https://github.com/jenkinsci/jenkins/pull/584

Raphau Nowak

unread,
Apr 28, 2013, 2:26:05 PM4/28/13
to jenkins...@googlegroups.com
Hi and thanks for response and pull request,
i hope this will be fast include in jenkins, but your patch exists over 4 months and nothing happens...

oliver gondža

unread,
May 11, 2013, 3:44:44 AM5/11/13
to Raphau Nowak, jenkins...@googlegroups.com
Hi, This feature will be in 1.515.[1]

[1] http://jenkins-ci.org/changelog (What's new in 1.515)
Reply all
Reply to author
Forward
0 new messages