maikvandergaag / msft-extensions

Repository for extensions mainly used for Azure DevOps Extensions
https://msftplayground.com
MIT License
126 stars 81 forks source link

Trigger release pipeline from build - Variabile Input #430

Closed garcia117 closed 1 year ago

garcia117 commented 1 year ago

Try to trigger a Release pipeline from yaml build pipeline I have to pass parameter through VariableImput json param but I Don't understand how to pass json, es. { 'version' : 'x.y.z' }

passing VariableInput: '{''version'' : ''x.y.z''}' It's returns: The release name *-$$REV1$$ [refs/heads/*****] contains invalid character(s). Characters which are not allowed include '"', '/', ':', '', '\', '|', '?', '@', and '*'.**

Trying with different pattern it returns: ##[error]Supplied json for the variables is not in the correct format!

How can I resolve the issue?

maikvandergaag commented 1 year ago

The release variable should be in the format: {'name' : 'test', 'newValue' : 'test'}

adityagu0910 commented 1 year ago

@garcia117 Could you please share your example of pipeline how you are using this passed variable in parameter of pipeline that is being triggered ?

I have same requirement as I need to pass 'isRelease' parameter to my main build pipeline and values could be 'PRERELEASE, PATCH, MINOR or MAJOR'