-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
Jenkins ver. 2.222.1
I used to do the following in the Jenkins file
library identifier: "pipeline-helper@$env.BRANCH_NAME", retriever: modernSCM( [$class: 'GitSCMSource', remote: 'https://scm.sc.intra/scm/jenkins/pipeline-helper.git', credentialsId: 'bitbucket.service.user' ]) defaultCipipelineMaven { nodes = 'devops' /* label of jenkins nodes*/ email = 'yz@comapny.org' }
The usage of `$env.BRANCH_NAME` made it easy to test changes of a feature branch of the `pipeline-helper` without that I had to manually change the branch identifier. This worked well until now where this suddenly results in an error
ERROR: Could not resolve null hudson.plugins.git.GitException: Command "D:\jenkins\tools\git\bin\git.exe rev-parse "null^{commit}"" returned status code 128: stdout: null^{commit} stderr: fatal: ambiguous argument 'null^{commit}': unknown revision or path not in the working tree. Use '--' to separate paths from revisions, like this: 'git <command> [<revision>...] -- [<file>...]'
I recently updated from the previous LTS version 2.204 but not sure if that's when it started failing...