Action parameter query - taking defaults from a properties file?

(imported topic written by hermann_huebler@at.ibm.com)

I’d need to prompt for several parameters for a fixlet however most of the parameters will not change between systems and fixlet invocations.

Therefore I’d like to make life easy for the operators and prompt for the parameters whereby each value should be defaulted to a value taken from a props file (don’t want to hard-code these).

The code should look similar to the following:

"__globalPropsFile" = "myProps.props"
parameter "*bold*__softwareLocation*bold*" = "{key "software.repository.root" of file (parameter "__globalPropsFile") of client folder of current site}"
action parameter query "installLocation" with description "Installation location" with default {parameter "*bold*__softwareLocation*bold*"}

As per the documentation this does not work (and tested that too) as relevance substitution is NOT performed on the action parameter query command line itself.

Does anybody know a “trick” how I can implement that on TEM v8.2 in a different way?

(imported comment written by hermann_huebler@at.ibm.com)

Sorry - there was a copy paste error in the original thread. That’s the sample code:

parameter "__globalPropsFile" = "myProps.props"
parameter "__softwareLocation" = "{key "software.repository.root" of file (parameter "__globalPropsFile") of client folder of current site}"
action parameter query "installLocation" with description "Installation location" with default {parameter "__softwareLocation"}

(imported comment written by jeremylam)

Right, action parameter queries are a bit different than normal client commands since they are resolved on the Console before endpoints know anything about it (and therefore cannot do relevance substitution).

You can simulate your desired behavior by making a blank parameter equivalent to “use the default as per the client properties file”:

code

action parameter query “installLocation” with description “Installation location (or use blank for default)”

if {parameter “installLocation” = “”}

parameter “installLocation” = {parameter "

bold

__softwareLocationbold"}

endif

// rest of action

code