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

Re: Now What?

From
Daniel Barkalow <barkalow@iabervon.org>
Date
Nov 4, 2005, 17:06 UTC
Message-ID
<Pine.LNX.4.64.0511041158350.25300@iabervon.org>
In-Reply-To
<7vll05bd1w.fsf@assigned-by-dhcp.cox.net>
On Thu, 3 Nov 2005, Junio C Hamano wrote:
Show 39 quoted lines
> Daniel Barkalow <barkalow@iabervon.org> writes:
> 
> > On Thu, 3 Nov 2005, Junio C Hamano wrote:
> >
> >> "Peter Eriksen" <s022018@student.dtu.dk> writes:
> >> 
> >> > ~/git/git-core]cat .git/remotes/origin
> >> > URL: git://git.kernel.org/pub/scm/git/git.git
> >> > Pull: master:origin
> >> >
> >> > ~/git/git-core]git-checkout maint
> >> > ~/git/git-core]git pull
> >> 
> >> You are merging my master into your "maint", probably a copy of
> >> my (previous) maint.
> >
> > I think the situation is that he really wanted to update master, but 
> > forgot that he was on the maint branch.
> 
> I wonder if it would make sense to have something in .git/remotes/
> file that says "run merge only when I am on frotz branch", like
> this:
> 
>         ~/git/git-core]cat .git/remotes/origin
>         URL: git://git.kernel.org/pub/scm/git/git.git
>         Pull: master:origin
> 	Fetch-Only-Unless: master
> 
>         ~/git/git-core]git-checkout maint
> 	~/git/git-core]git pull
> 	warning: not merging because you are not on 'master' branch.
> 
> This would make the above "git pull" behave identical to "git
> fetch", and the user can then do:
> 
> 	$ git checkout master
>         $ git pull . origin
> 
> Useful?  Useless?

People probably want to merge master into their personal work branches, though; I think it would be better to have it list branches into which it shouldn't be merged. I think the pair of "maint" and "master" are special, in that they get different fixes for the same problems, and so they'll merge badly or to a wrong result.

	-Daniel
*This .sig left intentionally blank*
Previous: Josef WeidendorferNext: Linus Torvalds
Message 14 of 20 in “Now What?”
  1. Jon LoeligerNov 3, 2005
  2. Chris ShoemakerNov 3, 2005
  3. Junio C HamanoNov 3, 2005
  4. Jon LoeligerNov 3, 2005
  5. Junio C HamanoNov 6, 2005
  6. Peter EriksenNov 3, 2005
  7. Junio C HamanoNov 3, 2005
  8. Daniel BarkalowNov 3, 2005
  9. Linus TorvaldsNov 3, 2005
  10. Junio C HamanoNov 3, 2005
  11. Peter EriksenNov 3, 2005
  12. Junio C HamanoNov 3, 2005
  13. Josef WeidendorferNov 3, 2005
  14. Daniel BarkalowNov 4, 2005
  15. Linus TorvaldsNov 3, 2005
  16. Junio C HamanoNov 3, 2005
  17. Junio C HamanoNov 3, 2005
  18. Josef WeidendorferNov 3, 2005
  19. Junio C HamanoNov 3, 2005
  20. Josef WeidendorferNov 3, 2005

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.