public inbox for git@vger.kernel.org 
 help / color / mirror / Atom feed
From: Phillip Susi <psusi@ubuntu•com>
To: Jeff King <peff@peff•net>
Cc: Chris Packham <judge.packham@gmail•com>,
	"git@vger•kernel.org" <git@vger•kernel.org>
Subject: Re: New directory lost by git am
Date: Wed, 05 Mar 2014 11:47:12 -0500	[thread overview]
Message-ID: <53175510.7020000@ubuntu.com> (raw)
In-Reply-To: <20140305163415.GA28908@sigill.intra.peff.net>

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 3/5/2014 11:34 AM, Jeff King wrote:
> I don't think those steps are necessary for Chris's example. When
> he switches back to the master branch, git removes the subdirectory
> (the file is tracked in "temp" but not "master", so we remove it
> when switching branches, and then the directory is empty, so we
> clean it up, too). You can verify with an extra "ls" after the
> checkout but before the "am".

Right.

>>> * "git apply" parsed patches that add new files, generated by 
>>> programs other than Git, incorrectly.  This is an old breakage
>>> in v1.7.11.
>>> 
>>> Does that sound like your problem? If you can I'd suggest 
>>> updating, ideally to the recent 1.9.0 release but if you're
>>> feeling conservative try 1.8.3.4.
>> 
>> Vaguely, except for the "other than git" part.  This patch was 
>> generated by git-format-patch ( I didn't think apply handled
>> patches that weren't ).
> 
> I can't get Chris's script to fail on any version of git. Can you
> show us an example of a patch that does not behave (or better yet,
> a reproduction recipe to generate the patch with "format-patch")?

AHA!  It requires a conflict.  There were simple conflicts in the NEWS
file so I applied the patch with git am --reject and fixed up the
NEWS, and ran git am --resolved.  The git am --reject fails to add the
new directory to the index.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.17 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJTF1UOAAoJEI5FoCIzSKrwTD4H/35pUf8DFsbwPIVVQi+8I8e3
5NMHwQrHK3TPbZigVPBgVfwRCtOAxX656BPhninfhix99HWs00W5zGaFDwkymRNp
87EeU3LVcIjapqijszw9AqwBLvfm9uzXEus964hShCJVOmKBezQfl6Mvcrkn5Na1
UchJLkRzEoi6VUyUso8FH0xpL7JyjF08H19dtvXoUbrvrXYuN1Ys3UMBHXVEVdi+
5O924lo4+psgdjGZ3HUpclYRbKO0LS5IVMCxFRw5Q+EfARJQ7NXzv/csRXIKyms7
roCQqmQnnem71GHx6SQaepnY5pKuEnmmDaqXbCOqZdpyfo1CB7SFJDq/VXrbLyw=
=zS2r
-----END PGP SIGNATURE-----

  reply	other threads:[~2014-03-05 16:47 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-03-05  2:49 New directory lost by git am Phillip Susi
2014-03-05  3:08 ` Chris Packham
2014-03-05  3:22   ` Phillip Susi
2014-03-05  8:10     ` Chris Packham
2014-03-05 14:26       ` Phillip Susi
2014-03-05 16:34         ` Jeff King
2014-03-05 16:47           ` Phillip Susi [this message]
2014-03-05 17:13             ` Jeff King
2014-03-05 18:29               ` Phillip Susi
2014-03-05 19:10               ` Junio C Hamano

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=53175510.7020000@ubuntu.com \
    --to=psusi@ubuntu$(echo .)com \
    --cc=git@vger$(echo .)kernel.org \
    --cc=judge.packham@gmail$(echo .)com \
    --cc=peff@peff$(echo .)net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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