From: Duy Nguyen <pclouds@gmail.com>
To: Eric Sunshine <sunshine@sunshineco.com>
Cc: "Git Mailing List" <git@vger.kernel.org>,
"Johannes Schindelin" <Johannes.Schindelin@gmx.de>,
"Ævar Arnfjörð Bjarmason" <avarab@gmail.com>,
"Stefan Beller" <sbeller@google.com>
Subject: Re: [RFC PATCH 0/5] format-patch: automate cover letter range-diff
Date: Thu, 7 Jun 2018 17:09:05 +0200 [thread overview]
Message-ID: <CACsJy8D696DiWLGJgfqECBDJ9rMbpOy5bCe_knTttmR82QPCJA@mail.gmail.com> (raw)
In-Reply-To: <CAPig+cS1M3U0T7yd2hKv4Uv1NMub20bTy13-D-6drpJLJjNNAA@mail.gmail.com>
On Thu, Jun 7, 2018 at 10:34 AM, Eric Sunshine <sunshine@sunshineco.com> wrote:
> On Wed, Jun 6, 2018 at 3:16 PM, Duy Nguyen <pclouds@gmail.com> wrote:
>> On Wed, May 30, 2018 at 10:03 AM, Eric Sunshine <sunshine@sunshineco.com> wrote:
>>> Dscho recently implemented a 'tbdiff' replacement as a Git builtin named
>>> git-branch-diff[1] which computes differences between two versions of a
>>> patch series. Such a diff can be a useful aid for reviewers when
>>> inserted into a cover letter. However, doing so requires manual
>>> generation (invoking git-branch-diff) and copy/pasting the result into
>>> the cover letter.
>>
>> Another option which I wanted to go is delegate part of cover letter
>> generation to a hook (or just a config key that contains a shell
>> command). This way it's easier to customize cover letters. We could
>> still have a good fallback that does shortlog, diffstat and tbdiff.
>
> It is common on this mailing list to turn down requests for new hooks
> when the requested functionality could just as easily be implemented
> via a wrapper script. So, my knee-jerk reaction is that a hook to
> customize the cover letter may be overkill when the same functionality
> could likely be implemented relatively easily by a shell script which
> invokes git-format-patch and customizes the cover letter
> after-the-fact. Same argument regarding a config key holding a shell
> command. But, perhaps there are cases which don't occur to me which
> could be helped by a config variable or such.
I think format-patch --cover-letter nowadays does more stuff that's
not so easy to simply rewrite it in a shell script. My original
problem with format-patch is it hard codes shortlog settings and you
can't list patches with patch number (e.g. "[1/2] foo bar"). The
simplest way is let format-patch does it stuff as usual and
"outsource" some cover letter's body generation to a script.
But it's ok. I could try to code the patch numbering thing in
format-patch and maybe submit a patch or two for that later.
> Of course, by the same reasoning, the --range-diff functionality
> implemented by this patch series, which is just a convenience, could
> be handled by a wrapper script, thus is not strictly needed. On the
> other hand, given that interdiffs and range-diffs are so regularly
> used in re-rolls on this list (and perhaps other mailing list-based
> projects) may be argument enough in favor of having such an option
> built into git-format-patch.
--
Duy
next prev parent reply other threads:[~2018-06-07 15:09 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-30 8:03 [RFC PATCH 0/5] format-patch: automate cover letter range-diff Eric Sunshine
2018-05-30 8:03 ` [RFC PATCH 1/5] format-patch: allow additional generated content in make_cover_letter() Eric Sunshine
2018-07-17 10:15 ` Johannes Schindelin
2018-07-17 10:24 ` Eric Sunshine
2018-05-30 8:03 ` [RFC PATCH 2/5] format-patch: add --range-diff option to embed diff in cover letter Eric Sunshine
2018-07-17 10:30 ` Johannes Schindelin
2018-07-17 10:49 ` Eric Sunshine
2018-07-26 10:55 ` Johannes Schindelin
2018-07-26 20:57 ` Eric Sunshine
2018-07-27 15:18 ` Johannes Schindelin
2018-05-30 8:03 ` [RFC PATCH 3/5] format-patch: extend --range-diff to accept revision range Eric Sunshine
2018-05-30 18:58 ` Stefan Beller
2018-05-30 20:26 ` Eric Sunshine
2018-07-17 10:44 ` Johannes Schindelin
2018-07-17 10:50 ` Eric Sunshine
2018-05-30 8:03 ` [RFC PATCH 4/5] format-patch: teach --range-diff to respect -v/--reroll-count Eric Sunshine
2018-05-30 19:03 ` Stefan Beller
2018-05-30 20:44 ` Eric Sunshine
2018-05-30 21:03 ` Stefan Beller
2018-05-30 21:14 ` Eric Sunshine
2018-05-30 8:03 ` [RFC PATCH 5/5] format-patch: add --creation-weight tweak for --range-diff Eric Sunshine
2018-07-17 11:00 ` Johannes Schindelin
2018-05-30 9:25 ` [RFC PATCH 0/5] format-patch: automate cover letter range-diff Ævar Arnfjörð Bjarmason
2018-06-06 19:16 ` Duy Nguyen
2018-06-07 8:34 ` Eric Sunshine
2018-06-07 15:09 ` Duy Nguyen [this message]
2018-07-17 10:04 ` Johannes Schindelin
2018-07-26 12:03 ` Andrei Rybak
2018-07-26 15:57 ` Johannes Schindelin
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
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=CACsJy8D696DiWLGJgfqECBDJ9rMbpOy5bCe_knTttmR82QPCJA@mail.gmail.com \
--to=pclouds@gmail.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=avarab@gmail.com \
--cc=git@vger.kernel.org \
--cc=sbeller@google.com \
--cc=sunshine@sunshineco.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.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
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 read-only IMAP folder(s) and NNTP newsgroup(s).