jenkinsci / jenkinsci/git-plugin

[JENKINS-46588] Pipeline Branch Specifier "blank for 'any'" fails

Open
#3,184 14 comments 0 reactions 0 assignees View on GitHub
component:git-plugin imported-jira-issue pipeline priority:minor resolution:unresolved
Dominant language
Java
Stars
694
Forks
1.1k
Avg merge
1h 29m
Merged PRs (30d)
3

Description

In Pipeline Job, "Branches to build configuration" it's said "blanck for any" but it fails when I manually trigger the build with :

java.lang.IllegalArgumentException: Invalid refspec refs/heads/**

see screen shots for more details

is there any other way to build all branches?

Work around the issue by disabling lightweight checkout in the job definition

---
Originally reported by flopic, imported from: Pipeline Branch Specifier "blank for 'any'" fails


  • status: Open
  • priority: Minor
  • component(s): git-plugin
  • label(s): Pipeline
  • resolution: Unresolved
  • votes: 7
  • watchers: 11
  • imported: 2025-12-02

Raw content of original issue

In Pipeline Job, "Branches to build configuration" it's said "blanck for any" but it fails when I manually trigger the build with :
java.lang.IllegalArgumentException: Invalid refspec refs/heads/**
see screen shots for more details

is there any other way to build all branches?

Work around the issue by disabling lightweight checkout in the job definition

  • environment: Jenkins ver. 2.60.3 and 2.73.1

2 attachments

- [Config_pipeline.JPG](https://issues.jenkins.io/secure/attachment/39552/Config_pipeline.JPG)
> ![Config_pipeline.JPG](https://issues.jenkins.io/secure/attachment/39552/Config_pipeline.JPG)
- [brancherror.JPG](https://issues.jenkins.io/secure/attachment/39553/brancherror.JPG)
> ![brancherror.JPG](https://issues.jenkins.io/secure/attachment/39553/brancherror.JPG)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.