Opened 5 years ago

Last modified 4 years ago

#2519 new enhancement

Git source step should support full (all-refs) fetches

Reported by: exarkun Owned by:
Priority: major Milestone: 0.9.+
Version: 0.8.7p1 Keywords: git
Cc:

Description

Largely because of the way the fetch step is done:

git fetch -t repo branch

Branch refs in the clone are roughly meaningless.

Better would be to simply:

git fetch -t repo

Or, I dunno, this probably works:

git fetch -t

This way, refs like origin/master actually point at the right place in the clone. As a bonus, this would make commands like:

git reset --hard branch --

work, instead of needing to figure out a revision hash. This would seem to simplify the rest of the Git source step's job.

Change History (4)

comment:1 Changed 5 years ago by dustin

The current implementation tries not to fetch branches that it has not been asked to build.

I'm not sure what you mean by "branch refs in the clone" - is it failing to find the right source code?

comment:2 Changed 5 years ago by exarkun

The current implementation tries not to fetch branches that it has not been asked to build.

A mode where it just fetched everything would be nice, then.

I'm not sure what you mean by "branch refs in the clone" - is it failing to find the right source code?

Yes - for any branch which is not the branch being built.

comment:3 Changed 5 years ago by dustin

  • Milestone changed from undecided to 0.8.+
  • Summary changed from Git source step should update refs to Git source step should support full (all-refs) fetches
  • Type changed from undecided to enhancement

comment:4 Changed 4 years ago by dustin

  • Milestone changed from 0.8.+ to 0.9.+

Ticket retargeted after milestone closed

Note: See TracTickets for help on using tickets.