Re: [PATCH 2/2] format-patch: add an option to suppress commit hash

2015-12-08 Thread Junio C Hamano
"brian m. carlson" writes: >> Don't test "any number of '0'"; test 40 '0's. This is because the >> line format was designed to be usable by things like /etc/magic to >> detect format-patch output, and we want to notice if/when we break >> that aspect of our output

Re: [PATCH 2/2] format-patch: add an option to suppress commit hash

2015-12-07 Thread Junio C Hamano
"brian m. carlson" writes: > Oftentimes, patches created by git format-patch will be stored in > version control or compared with diff. In these cases, two otherwise > identical patches can have different commit hashes, leading to diff > noise. Teach git

Re: [PATCH 2/2] format-patch: add an option to suppress commit hash

2015-12-07 Thread Junio C Hamano
Junio C Hamano writes: >> +--no-hash:: >> + Output an all-zero hash in each patch's From header instead >> + of the hash of the commit. >> + > > Two (big) problems with the option name. > > - "--no-something" would mislead people to think you are removing >something,

Re: [PATCH 2/2] format-patch: add an option to suppress commit hash

2015-12-07 Thread brian m. carlson
On Mon, Dec 07, 2015 at 11:34:59AM -0800, Junio C Hamano wrote: > Two (big) problems with the option name. > > - "--no-something" would mislead people to think you are removing >something, not replacing it with something else. This option >does the latter (i.e. the first line of your

[PATCH 2/2] format-patch: add an option to suppress commit hash

2015-12-06 Thread brian m. carlson
Oftentimes, patches created by git format-patch will be stored in version control or compared with diff. In these cases, two otherwise identical patches can have different commit hashes, leading to diff noise. Teach git format-patch a --no-hash option that instead produces an all-zero hash to