Is it possible to pass result of the shell command to Kotlin variable?

Answered
3
1 comment

Hello!

Could you please elaborate on your case? If you need to, say, pass a parameter between steps, then you could use service messages feature to create or update a build parameter in one step, and then use it in the following one. For instance, you could use this command to set a parameter:

myVar=myCommand
echo "##teamcity[setParameter name='myValue' value='$myValue']"

The next step could reference %myVar% to get the value.

0

Please sign in to leave a comment.