Modify a Jenkins build def using java api
I wish to change the rtc workspace parameter in a jenkins build def.
I assume I would see the property running the following code
List <IBuildConfigurationElement> elements = buildDef.getConfigurationElements();
for (int k = 0;k < elements.size();k++){
System.out.println("name " + elements.get(k).getName());
System.out.println("id " + elements.get(k).getElementId());
List <IConfigurationProperty> props = elements.get(k).getConfigurationProperties();
for (int i = 0;i < props.size();i++){
String name = props.get(i).getName();
String value = props.get(i).getValue();
System.out.println("name:" + name + "---value:" + value);
}
System.out.println("************************************************");
}
The output is the following for jazz source control element.
name Jazz Source Control
id com.ibm.team.build.jazzscm
name:com.ibm.team.build.engine.variable.substitution---value:
************************************************
I assume I am missing something which give me the source control props
I assume I would see the property running the following code
List <IBuildConfigurationElement> elements = buildDef.getConfigurationElements();
for (int k = 0;k < elements.size();k++){
System.out.println("name " + elements.get(k).getName());
System.out.println("id " + elements.get(k).getElementId());
List <IConfigurationProperty> props = elements.get(k).getConfigurationProperties();
for (int i = 0;i < props.size();i++){
String name = props.get(i).getName();
String value = props.get(i).getValue();
System.out.println("name:" + name + "---value:" + value);
}
System.out.println("************************************************");
}
The output is the following for jazz source control element.
name Jazz Source Control
id com.ibm.team.build.jazzscm
name:com.ibm.team.build.engine.variable.substitution---value:
************************************************
I assume I am missing something which give me the source control props