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

Re: git push

From
Finn Arne Gangstad <finnag@pvv.org>
Date
Mar 5, 2009, 09:44 UTC
Message-ID
<20090305094410.GA26120@pvv.org>
In-Reply-To
<49AF9117.1020407@op5.se>
On Thu, Mar 05, 2009 at 09:45:11AM +0100, Andreas Ericsson wrote:
> Worst-case scenario, you commits that were never intended for publication
> enter your public wateringhole and needs a revert later on. Big deal.

It could be a very big deal depending on what the contents are. I think you can split developers in two groups - those who like to learn a lot about version control systems, and those who just see it as a necessary evil to get their job done. The latter seems to be the majority.

The first group will know how to undo the damage from a bad push (and probably configure their setup so they do not necessarily happen), while the second group will not necessarily notice that it happened or know how to undo it. So, bad pushes go through, and are not detected before 3 other people base their work on it, and we get a lot of hassle.

Show 7 quoted lines
>> It is not realistic to believe that in a big project with many
>> developers, no one will ever do the mistake of typing "git push".  It
>> is also not realistic to believe that everyone will know how to (or
>> remember to) configure this away.
>
> But it *is* realistic to not assume that they will also use --force
> while doing so.

Our public repos are set up so that only a few chosen people are allowed to force pushes, so this is not an issue for us.

Show 7 quoted lines
>> If "git push" could do nothing at all without configuring anything, that
>> would be a big improvement to us.
>
> I can buy this, I guess. I always type the remote-name I want to push to
> anyways. A sane no-op default would probably be to list the pre-configured
> remotes along with a short usage message. I still don't quite see the point
> of it.

I'll try to whip up a small patch series tonight and see what it ends up looking like.

- Finn Arne
Previous: John Tapsell
Message 17 of 17 in “git push”
  1. John TapsellFeb 25, 2009
  2. Jeff KingFeb 25, 2009
  3. Junio C HamanoFeb 25, 2009
  4. John TapsellFeb 25, 2009
  5. Junio C HamanoFeb 25, 2009
  6. Jeff KingFeb 25, 2009
  7. Junio C HamanoFeb 25, 2009
  8. Jeff KingFeb 25, 2009
  9. John TapsellFeb 25, 2009
  10. Junio C HamanoFeb 25, 2009
  11. John TapsellFeb 25, 2009
  12. Jay SoffianFeb 25, 2009
  13. Junio C HamanoFeb 25, 2009
  14. Finn Arne GangstadFeb 25, 2009
  15. Andreas EricssonMar 5, 2009
  16. John TapsellMar 5, 2009
  17. Finn Arne GangstadMar 5, 2009

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.