From: Alan Mackenzie <acm@muc.de>
To: Ingo Lohmar <i.lohmar@gmail.com>
Cc: Emacs developers <emacs-devel@gnu.org>,
Kaushal Modi <kaushal.modi@gmail.com>
Subject: Re: Understanding a recent commit in emacs-25 branch [ed19f2]
Date: Sun, 3 Apr 2016 12:14:58 +0000 [thread overview]
Message-ID: <20160403121458.GC3537@acm.fritz.box> (raw)
In-Reply-To: <87lh4uex9h.fsf@acer.localhost.com>
Hello, Ingo.
On Sun, Apr 03, 2016 at 01:40:10PM +0200, Ingo Lohmar wrote:
> Hi Alan,
> On Sun, Apr 03 2016 11:17 (+0000), Alan Mackenzie wrote:
> > That massive commit happened because of git. I attempted a 'git pull'
> > prior to making a (moderately small) commit. There was a one-letter
> > typo in one of my existing files (which I think had been committed).
> > Because of that, git failed to merge in all the stuff which it had just
> > fetched from savannah, instead prompting me to do a manual merge, which
> > I then did.
> I think 'git pull' has been discussed on this list before. Others feel
> differently about this issue, but I strongly advise anyone against using
> 'git pull', and instead suggest you do 'git fetch' (maybe --all).
> *After* seeing what has happened to the remote branches, you can decide
> whether a merge or a rebase is in order. Or you spot an unwanted
> discrepancy, and can fix it, instead of git telling you to manually
> merge (although admittedly I do not quite follow that part).
Is there a way of asking "if I attempt git merge, will there be any
conflicts?"? It would be nice to find this out before one's working
directory gets lots of uncommitted changes.
Is there a way of recovering after doing git pull, when git has already
written all the pulled changes to the working directory? Is there some
way of saying git undo-partial-pull, leaving the working directory as it
was before the pull, and cancelling the merge which git has started?
> > It would also be nice if such "pseudo merges" could be handled locally,
> > rather than being pushed back to the remote repository, causing
> > confusion.
> Please note that *all* commits and merges happen locally. The user can
> only push changes back to the remote by an explicit action, with all
> intended and unintended effects.
Sorry, I wasn't very clear. What I meant was, is there a way of
finishing the merge locally, then pushing real changes without the
confusing "pseudo-merge" escaping upstream with them?
When I did git pull, there were, let's say, 20 commits. 19 of these
could have been moved directly into my local repository; only one had a
conflict. It would be nice to be able to fix the local repo, so that
the "pseudo-merge" of these 19 blameless commits remains a purely local
affair, and doesn't get pushed upstream.
--
Alan Mackenzie (Nuremberg, Germany).
next prev parent reply other threads:[~2016-04-03 12:14 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-04-01 5:32 Understanding a recent commit in emacs-25 branch [ed19f2] Kaushal Modi
2016-04-01 5:43 ` Kaushal Modi
2016-04-01 6:43 ` Paul Eggert
2016-04-03 12:03 ` Alan Mackenzie
2016-04-03 12:10 ` Achim Gratz
2016-04-03 14:18 ` Stefan Monnier
2016-04-03 14:49 ` Óscar Fuentes
2016-04-03 18:15 ` Achim Gratz
2016-04-03 18:45 ` Andreas Schwab
2016-04-03 18:56 ` Eli Zaretskii
2016-04-03 20:02 ` Paul Eggert
2016-04-03 21:15 ` Andreas Schwab
2016-04-03 23:11 ` John Wiegley
2016-04-03 12:18 ` Ingo Lohmar
2016-04-03 11:17 ` Alan Mackenzie
2016-04-03 11:27 ` Andreas Schwab
2016-04-03 11:40 ` Ingo Lohmar
2016-04-03 12:14 ` Alan Mackenzie [this message]
2016-04-03 12:30 ` Ingo Lohmar
2016-04-03 14:12 ` Andreas Schwab
2016-04-03 14:57 ` Ingo Lohmar
2016-04-03 15:08 ` Andreas Schwab
2016-04-03 15:12 ` Eli Zaretskii
2016-04-03 15:01 ` Eli Zaretskii
2016-04-03 15:23 ` Ingo Lohmar
2016-04-03 15:40 ` Eli Zaretskii
2016-04-03 16:00 ` Ingo Lohmar
2016-04-03 16:19 ` Eli Zaretskii
2016-04-03 16:24 ` Andreas Schwab
2016-04-03 17:09 ` Eli Zaretskii
2016-04-03 17:35 ` Andreas Schwab
2016-04-03 18:04 ` Eli Zaretskii
2016-04-03 11:44 ` Dmitry Gutov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160403121458.GC3537@acm.fritz.box \
--to=acm@muc.de \
--cc=emacs-devel@gnu.org \
--cc=i.lohmar@gmail.com \
--cc=kaushal.modi@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.