Line breaks in default parameters
I'm experimenting with auto-merge, driven by a "prompt" parameter value, when all tests (dependencies) pass. This is so developers can 'fire and forget' when a branch is ready for integration, other than tests passing.
However we have a commit message template enforced by hooks, and the commit message is multi-line.
It seems you can enter linebreaks in parameters when running a build. But the default parameter value does not seem to support this. I tried using "\n" to encode a linebreak, to no avail.
Please advise, how can I configure a TeamCity parameter default value with linebreaks inside it?
I'm using 2018.1.4.
Thanks!
Please sign in to leave a comment.
Hi Steve,
I'm not sure I might be getting something wrong here, but you are trying to set up a usual build parameter, set it up as a prompt type, then add a default value with multiple lines? Just hitting enter on the textbox for "value" should create a new line. If I'm missing something please don't hesitate to mention it.
Denis. I'm not sure what I was doing, but you're right, I can create line breaks including trailing ones.
Maybe it just wasn't clear when the text box was only one line long? Or maybe it didn't work when the text was empty. I recall trying to configure this and every time I pressed Enter, it committed the dialog instead. Can't reproduce it now (for existing parameter).