Page MenuHomePhabricator

Make Phabricator clone bare git repositories
ClosedPublic

Authored by epriestley on Oct 27 2013, 4:12 AM.
Tags
None
Referenced Files
F18541824: D7430.diff
Sun, Sep 7, 9:43 PM
F18530494: D7430.id16756.diff
Sun, Sep 7, 1:31 AM
F18134082: D7430.id16756.diff
Wed, Aug 13, 11:35 PM
F18133465: D7430.id16756.diff
Wed, Aug 13, 10:58 PM
F18112774: D7430.id.diff
Tue, Aug 12, 8:27 PM
F18109224: D7430.diff
Mon, Aug 11, 12:38 PM
F18102784: D7430.id16724.diff
Aug 9 2025, 11:17 PM
F17949054: D7430.id16756.diff
Jul 31 2025, 10:46 PM
Subscribers

Details

Reviewers
btrahan
Maniphest Tasks
Restricted Maniphest Task
Commits
Restricted Diffusion Commit
rP59922b78b9bc: Make Phabricator clone bare git repositories
Summary

This doesn't really impact anything very much, but is a little cleaner than cloning repositories with a working copy. It's somewhat important for allowing pushes, because you can't push to a checked-out branch.

Mercurial has a similar option (--noupdate) but leave that alone for now.

The origin stuff was mostly for sanity/explicitness purposes -- I believe it's safe to remove in all non-ridiculous cases. Git fails with it in bare repositories (it automatically creates an origin, but doesn't create the local refs for it, or something).

Test Plan

Nuked a repo, re-cloned it, pulled and updated it several times. Browsed both bare and non-bare repos in Diffusion.

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped