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

RE: Files different for me

From
JDJohn Dlugosz <jdlugosz@tradestation.com>
Date
Feb 25, 2009, 18:02 UTC
Message-ID
<450196A1AAAE4B42A00A8B27A59278E709E0486D@EXCHANGE.trad.tradestation.com>
In-Reply-To
<7E43550E-68B7-4B22-A83C-F840A7037CA9@silverinsanity.com>
> Generally when I keep changes like this, I make a commit called "Local
> Changes" or similar and have branch.master.rebase set to true so that
> my changes get rebased on top of origin when I pull.

That sounds ideal. However, I don't understand the specific steps you mention. Looking in the help for git-config,

	branch.<name>.rebase
		When true, rebase the branch <name> on top of the
fetched branch, 
		instead of merging the default branch from the default
remote when 
		"git pull" is run. NOTE: this is a possibly dangerous
operation; 
		do not use it unless you understand the implications 
		(see git-rebase(1) for details).

So, assuming you are working on the "master" branch, this will rebase the pulled content on top of the existing "master" rather than merging. If my local changes are committed to "master" first, then this will take all the commits from other developers that I don't already have in my local copy and apply them on top of my existing (including Local Changes). But since those will now be different commits, what happens next time? Ah, "...which introduce the same textual changes..." so that's covered in how rebase works.

But this will have Local Changes present, and different commits (with the same textual changes) in my branch. So what happens when I "push"?

	Oldstuff--A--B--C  remote
	       \
	        LC--X--Y  mine

LC is "Local Changes", X and Y are changes I made, and A, B, C are changes from other developers.

After a fetch, I have:
	Oldstuff--LC--X--Y--A'--B'--C'  mine
So what happens when I "push"?
In any case, the whole point is that I don't want to publish LC.
Previous: Brian GernhardtNext: Brian Gernhardt
Message 3 of 17 in “Files different for me”
  1. John DlugoszFeb 25, 2009
  2. Brian GernhardtFeb 25, 2009
  3. John DlugoszFeb 25, 2009
  4. Brian GernhardtFeb 25, 2009
  5. John DlugoszFeb 25, 2009
  6. Matthieu MoyFeb 25, 2009
  7. Junio C HamanoFeb 25, 2009
  8. Linus TorvaldsFeb 25, 2009
  9. Junio C HamanoFeb 25, 2009
  10. Linus TorvaldsFeb 25, 2009
  11. Junio C HamanoFeb 25, 2009
  12. Linus TorvaldsFeb 25, 2009
  13. Jay SoffianFeb 25, 2009
  14. John DlugoszFeb 25, 2009
  15. John DlugoszFeb 25, 2009
  16. Junio C HamanoFeb 25, 2009
  17. Feanil PatelFeb 25, 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.