Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-26 Thread Junio C Hamano
Junio C Hamano writes: > Denton Liu writes: > >> Perhaps something like >> --cover-subject-from-description={true,auto,false}? > > Is it still only about "subject"? I thought one of the improved > behaviour was to populate the subject header with the title > (i.e. the first, often single-line,

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-26 Thread Junio C Hamano
Philip Oakley writes: > I haven't looked at what happens on Windows (CRLF usage?) for > multi-line descriptions. The common assumption is LF in repo, with > attributes etc, but the branch description is a bit free format in > terms of guidance ;-) The same approach taken by the format-patch to u

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-26 Thread Junio C Hamano
Denton Liu writes: > Perhaps something like > --cover-subject-from-description={true,auto,false}? Is it still only about "subject"? I thought one of the improved behaviour was to populate the subject header with the title (i.e. the first, often single-line, paragraph) and use the remainder in t

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-24 Thread Philip Oakley
On 24/08/2019 09:03, Denton Liu wrote: On Fri, Aug 23, 2019 at 01:18:44PM -0700, Junio C Hamano wrote: Philip Oakley writes: Perhaps the `--infer-cover-subject` the config option needs to be multi-valued to include: "subject" (always expect short first lines) or "message" (always

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-24 Thread Denton Liu
On Fri, Aug 23, 2019 at 01:18:44PM -0700, Junio C Hamano wrote: > Philip Oakley writes: > > > Perhaps the `--infer-cover-subject` the config option needs to be > > multi-valued to include: > > "subject" (always expect short first lines) or > > "message" (always the long paragraph descri

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-23 Thread Junio C Hamano
Philip Oakley writes: > Perhaps the `--infer-cover-subject` the config option needs to be > multi-valued to include: > "subject" (always expect short first lines) or > "message" (always the long paragraph description, still use > ***Subject Here***), > with the "true" being used wh

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-23 Thread Philip Oakley
On 23/08/2019 19:15, Denton Liu wrote: Having said that, I suspect that in the longer term, people would want to see this new behaviour with a bit of tweak become the new default. The "tweak" I suspect is needed is to behave sensibly when "the first line" ends up to be too long a subject. Wh

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-23 Thread Denton Liu
On Wed, Aug 21, 2019 at 12:32:19PM -0700, Junio C Hamano wrote: > Denton Liu writes: > > > Teach format-patch to use the first line of the branch description as > > the Subject: of the generated cover letter, rather than "*** SUBJECT > > I would not say "the first line", as I do not think that i

Re: [PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-21 Thread Junio C Hamano
Denton Liu writes: > Teach format-patch to use the first line of the branch description as > the Subject: of the generated cover letter, rather than "*** SUBJECT I would not say "the first line", as I do not think that is what happens by calling pretty.c::format_subject(). The function is desig

[PATCH v3 13/13] format-patch: learn --infer-cover-subject option

2019-08-20 Thread Denton Liu
Teach format-patch to use the first line of the branch description as the Subject: of the generated cover letter, rather than "*** SUBJECT HERE ***" if `--infer-cover-subject` is specified or the corresponding `format.inferCoverSubject` option is enabled. This complements the existing inclusion of