timja / jenkins-gh-issues-poc-06-18

0 stars 0 forks source link

[JENKINS-39185] Pipeline library name with hyphen is not available as an environment variable #3622

Open timja opened 7 years ago

timja commented 7 years ago

If I use a Library name such as pipeline-common, the library.pipeline-common.version environment variable is not available. When I try and using it in the SCM configuration (i.e. tags/${library.pipeline-common.version}), the literal value is used in the Git operations:

> git fetch --tags --progress https:///pipeline-common.git +refs/heads/*:refs/remotes/origin/*
 > git rev-parse tags/${library.pipeline-common.version}^{commit} # timeout=10

If I change the Library name to simply pipeline, the feature works as expected.


Originally reported by timeapen, imported from: Pipeline library name with hyphen is not available as an environment variable
  • status: Open
  • priority: Minor
  • resolution: Unresolved
  • imported: 2022/01/10
timja commented 7 years ago

jglick:

As you can see here, Jenkins core does not support hyphens (-) in variable names for purposes of macro substitution.