git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Coping with the pull-before-you-push model

From
Joshua Jensen <jjensen@workspacewhiz.com>
Date
Sep 9, 2010, 04:47 UTC
Message-ID
<4C8866F9.1040705@workspacewhiz.com>
  After a deployment of Git on a centralized server at my place of 
business, the largest amount of grumbling has been with the 
pull-before-you-push model.  Coming from the file-centric Perforce where 
you need only have latest of just the files you are submitting, the 
pull-before-you-push model has really been a pain in the neck for a 
large team.

Even with topic branches being used, merges to master occur frequently. It can really be a frustrating battle to get your merged branch pushed to the central master branch. In the time it took you to pull, test, and push, someone has probably already pushed before you. To cope with this, people will pull, not bother testing, and immediately push their changes. Yes, this could result in build instability, but it is considered better than never being able to make your change live.

(Let's ignore what we should or shouldn't be doing as far as 'development practices'. :) We're solving the problems one step at a time...)

Gerrit provides a compelling model where branches are pushed to the code review server in the form refs/for/master, and the given push will always succeed. Code reviews are performed, someone sets the verified bit, and the change is submitted and merged to master by Gerrit itself in a queued fashion. Unfortunately, its general "requirement" to squash your branch down to a single commit is, possibly, a showstopper. If it treated a branch merge as a group of commits that MUST stay together, that would be perfect.

What other tools are out there that would let users successfully push their branch to the server (without having the HEAD master commit), and the push would be automatically merged to the master branch?

Is there another workflow that is successful for your large(-ish) enterprise team?

Thanks for your insights!
Josh
Next: Ævar Arnfjörð Bjarmason
Message 1 of 14 in “Coping with the pull-before-you-push model”
  1. Joshua JensenSep 9, 2010
  2. Ævar Arnfjörð BjarmasonSep 9, 2010
  3. Joshua JensenSep 9, 2010
  4. Jon SeymourSep 10, 2010
  5. Jeff KingSep 10, 2010
  6. Joshua JensenSep 14, 2010
  7. Jeff KingSep 14, 2010
  8. Avery PennarunSep 14, 2010
  9. David BrownSep 15, 2010
  10. Theodore TsoSep 14, 2010
  11. Joshua JensenSep 14, 2010
  12. Eugene SajineSep 14, 2010
  13. Ted Ts'oSep 14, 2010
  14. Joshua JensenSep 14, 2010

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.