On Thu, Jun 10, 2010 at 16:51, Junio C Hamano <gitster@xxxxxxxxx> wrote: > Ævar Arnfjörð Bjarmason <avarab@xxxxxxxxx> writes: > >> Change git-am to ignore whitespace (as defined by sh's read) at the >> beginning of patches. >> >> Empty lines are wont to creep in at the beginning of patches, here's >> an example from a raw Gmail attachment: >> >> 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 | | >> 20 20 20 20 20 20 20 20 20 20 20 20 20 20 20 0a | .| >> 52 65 74 75 72 6e 2d 50 61 74 68 3a 20 3c 61 76 |Return-Path: <av| >> >> Whitespace is also likely to appear if the user copy/pastes the patch >> around, e.g. via a pastebin, or any any number of other cases. This >> harms nothing and makes git-am's detection more fault tolerant. > > Actually cut-and-paste is often a major source of whitespace breakage > (including tabs silently being expanded), and I personally think a patch > like this to encourage the practice is going in a wrong direction. It doesn't encourage that copy/paste. It's just tangentally mentioned in the commit message since it's a plausable use case. What it does is enable the GMail -> download -> git-am workflow. GMail (and doubtless countless other) E-Mail providers introduce whitespace at the beginning of raw E-Mail messages, while otherwise leaving them intact. -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html