Closed jkornata closed 3 years ago
Hi, Escape it with backslash
On Mon, 16 Nov 2020 at 11:42 jkornata notifications@github.com wrote:
I've successfully transitioned my Jenkins instance to My Bloody Jenkins version 2.235.5-215
The only exception is that one of the seed jobs has variable as a source branch. Unfortunately it doesn't work and with each Jenkins boot it sets the value to master (I assume it's default value).
managedConfig: seed_jobs: MyJobName: source: remote: link credentialsId: key branch: '${BRANCH_NAME}'
After each start I manually set it to desired value but each restart resets it.
Variable is defined in my pipeline file:
pipeline { agent { label 'master' } parameters { string(name: 'BRANCH_NAME', defaultValue: '')
Is there any way to avoid setting this value to master?
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/odavid/my-bloody-jenkins/issues/176, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAGSOAJMGED5KZ5RRSWBENDSQDXYNANCNFSM4TW52HXQ .
@jkornata
Like this:
managedConfig:
seed_jobs:
MyJobName:
source:
remote: link
credentialsId: key
branch: '\${BRANCH_NAME}'
Thank you. I'm sorry, must have missed this information in the docs.
I've successfully transitioned my Jenkins instance to My Bloody Jenkins version
2.235.5-215
The only exception is that one of the seed jobs has variable as a source branch. Unfortunately it doesn't work and with each Jenkins boot it sets the value to
master
(I assume it's default value).After each start I manually set it to desired value but each restart resets it.
Variable is defined in my pipeline file:
Is there any way to avoid setting this value to
master
?