git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Boyd Stephen Smith Jr." <bss@iguanasuicide.net>
Cc: git@vger.kernel.org, Nanako Shiraishi <nanako3@lavabit.com>
Subject: Re: [PATCH] Have manpage reference new documentation on reverting merges.
Date: Sat, 20 Dec 2008 18:36:43 -0800	[thread overview]
Message-ID: <7vtz8ytft0.fsf@gitster.siamese.dyndns.org> (raw)
In-Reply-To: 200812201832.48992.bss@iguanasuicide.net

"Boyd Stephen Smith Jr." <bss@iguanasuicide.net> writes:

> Signed-off-by: Boyd Stephen Smith Jr <bss@iguanasuicide.net>
> ---
> An example addition to the manpage for revert that references Nanako
> Shiraishi's new documentation.
>
>  Documentation/git-revert.txt |    4 ++++
>  1 files changed, 4 insertions(+), 0 deletions(-)
>
> diff --git a/Documentation/git-revert.txt b/Documentation/git-revert.txt
> index caa0729..ea36bdf 100644
> --- a/Documentation/git-revert.txt
> +++ b/Documentation/git-revert.txt
> @@ -45,6 +45,10 @@ OPTIONS
>  	the mainline and allows revert to reverse the change
>  	relative to the specified parent.
>  
> +	Reverting a merge commit does not completely "undo" the effect of the
> +	merge and it may make future merges more difficult.  For more details,
> +	please read Documentation/howto/revert-a-faulty-merge.txt.
> +

I think these new lines need to be dedented, and the previous blank line
should be turned into a line with a single '+'.

I'd also suggest removing "does not ... merge and it" from the above
sentence to avoid confusing readers, because people who read only the
above and do not read the howto document may get a wrong impression that
the resulting tree may have some changes that came from the merge even
after the revert, which is not the case.  Revert will erase the effect the
merge had to your tree and that part is complete.

Linus's "does not completely undo" only refers to the history part of the
merge, and that only affects future re-merges from the same branch, which
the reader who is interested in doing a revert of a merge right now (that
is why s/he is reading this paragraph) may not yet care about.

An alternative is to give a complete but brief explanation.  Perhaps like
this:

    By reverting a merge, you are declaring that you will never want the
    changes that were brought in by that merge you are reverting in your
    tree.  If you do merge from the same branch again in the future after
    it is updated, git remembers your declaration, and only the changes on
    the branch that were made after the reverted merge will be brought in.
    This may or may not be what you want.  See 'revert-a-faulty-merge'
    HOWTO for more details.

  reply	other threads:[~2008-12-21  2:38 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-12-21  0:32 [PATCH] Have manpage reference new documentation on reverting merges Boyd Stephen Smith Jr.
2008-12-21  2:36 ` Junio C Hamano [this message]
2008-12-21  5:35   ` Boyd Stephen Smith Jr.
2008-12-21  8:00     ` Junio C Hamano
2008-12-21 21:35   ` [PATCHv2] " Boyd Stephen Smith Jr.
2008-12-21 21:54     ` Junio C Hamano
2008-12-22  0:26       ` [PATCHv3] Have git revert documentation reference new HOWTO on reverting faulty merges Boyd Stephen Smith Jr.

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=7vtz8ytft0.fsf@gitster.siamese.dyndns.org \
    --to=gitster@pobox.com \
    --cc=bss@iguanasuicide.net \
    --cc=git@vger.kernel.org \
    --cc=nanako3@lavabit.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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).