git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* git send-email improvements
@ 2008-10-31 10:57 Pierre Habouzit
  2008-10-31 10:57 ` [PATCH 1/3] git send-email: avoid leaking directory file descriptors Pierre Habouzit
                   ` (3 more replies)
  0 siblings, 4 replies; 62+ messages in thread
From: Pierre Habouzit @ 2008-10-31 10:57 UTC (permalink / raw)
  To: git

The teaser
==========

This series has been sent using:
  git send-email --to git@vger.kernel.org --compose --annotate HEAD~3..


The series
==========

Here is a patch series to improve git send-email following our
discussions at GitTogether'08, despite my hate for perl.

The first patch is a minor nitpick, because leaking fd's sucks.

The second patch allow git-send-email to receive revision lists as
arguments. This doesn't allow complex arguments combinations as it
proces the revision lists one by one (IOW ^$sha1 $sha2 won't work as
expected _at all_) but this shouldn't be a problem since this command is
primarily used for interactive users. People wanting to use
git-send-email with complex revision lists through scripts MUST
git-format-patch first into a safe temporary directory and use
git-send-email on this afterwards.

The last patch adds the possibility to review patches into an editor
before sending them, which allow you (thanks to patch 2) to serialize,
review, annotate, and send patches in one command.


Further discussion
==================

I think one could make git send-email better doing this:

(1) make --compose and --annotate default, do not asking for a Subject
    if it's missing, neither should we ask for the in-reply-to if it's
    missing.

    Then spawn the editor with a first empty file that contains rougly a
    template looking like this:

        ----8<----
        GIT: Purge this buffer from any content if you don't want a series summary
        GIT:
        GIT: Lines beginning in "GIT: " will be removed.
        GIT: Consider including an overall diffstat or table of contents
        GIT: for the patch you are writing.
        GIT:
        GIT: Please fill a Subject if missing
        GIT: Leave the In-Reply-To field empty if not applicable.
        Subject:
        In-Reply-To:
        --> <we may want to add some more headers here: To/Cc/Bcc/...>

        GIT: put the content of the mail below this line


        GIT: [PATCH 1/10] ....  \
        GIT: [PATCH 2/10] ....   | this would contain all the Subject's
        [...]                    | from the commits that are beeing sent
        GIT: [PATCH 8/10] ....   | as a conveniency for people not
        GIT: [PATCH 9/10] ....   | having to cut&paste them
        GIT: [PATCH 10/10] .... /
        ---->8----

    I suggest we don't enable --compose when the series is reduced to
    one patch, as the usual way is to comment inline. This is probably
    arguable.

(2) Introduce a --batch option that basically:
    * turns --compose and --annotate off
    * turns any interactive feature off
    * complain (and fail) if it misses any information that is usually
      asked interactively

What do you think ?

^ permalink raw reply	[flat|nested] 62+ messages in thread

end of thread, other threads:[~2008-11-15 22:08 UTC | newest]

Thread overview: 62+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-10-31 10:57 git send-email improvements Pierre Habouzit
2008-10-31 10:57 ` [PATCH 1/3] git send-email: avoid leaking directory file descriptors Pierre Habouzit
2008-10-31 10:57   ` [PATCH 2/3] git send-email: interpret unknown files as revision lists Pierre Habouzit
2008-10-31 10:57     ` [PATCH 3/3] git send-email: add --annotate option Pierre Habouzit
2008-10-31 21:34       ` Ian Hilt
2008-11-02  6:23       ` Junio C Hamano
2008-11-02  9:51         ` Pierre Habouzit
2008-11-03 12:18           ` Matthieu Moy
2008-10-31 16:52     ` [PATCH] git send-email: allow any rev-list option as an argument Pierre Habouzit
2008-11-02  4:35       ` Jeff King
2008-11-02  9:39         ` Pierre Habouzit
2008-11-02 18:02           ` Jeff King
2008-11-03  9:15             ` Pierre Habouzit
2008-11-04  1:04               ` Junio C Hamano
2008-11-04  8:19                 ` Pierre Habouzit
2008-11-02  4:31   ` [PATCH 1/3] git send-email: avoid leaking directory file descriptors Jeff King
2008-10-31 12:36 ` Further enhancement proposal for git-send-email Pierre Habouzit
2008-10-31 12:36   ` [PATCH 1/3] git send-email: make the message file name more specific Pierre Habouzit
2008-10-31 12:36     ` [PATCH 2/3] git send-email: do not ask questions when --compose is used Pierre Habouzit
2008-10-31 12:36       ` [PATCH 3/3] git send-email: turn --compose on when more than one patch Pierre Habouzit
2008-10-31 21:33       ` [PATCH 2/3] git send-email: do not ask questions when --compose is used Ian Hilt
2008-10-31 21:38         ` Pierre Habouzit
2008-10-31 22:01           ` Ian Hilt
2008-11-01  2:26     ` Ian Hilt
2008-11-01 11:04       ` Pierre Habouzit
2008-11-01 13:00         ` Ian Hilt
2008-11-01 17:08           ` Pierre Habouzit
2008-11-01 17:34             ` Francis Galiegue
2008-11-01 17:43               ` Pierre Habouzit
2008-11-01 19:56                 ` Francis Galiegue
2008-11-01 17:54             ` Ian Hilt
2008-11-02  6:18     ` [PATCH 1/3] git send-email: make the message file name more specific Junio C Hamano
2008-11-02  9:35       ` Pierre Habouzit
2008-11-02 21:34         ` Ian Hilt
2008-11-03  8:53           ` Pierre Habouzit
2008-11-04 16:24 ` [take 2] git send-email updates Pierre Habouzit
2008-11-04 16:24   ` [PATCH 1/5] git send-email: make the message file name more specific Pierre Habouzit
2008-11-04 16:24     ` [PATCH 2/5] git send-email: interpret unknown files as revision lists Pierre Habouzit
2008-11-04 16:24       ` [PATCH 3/5] git send-email: add --annotate option Pierre Habouzit
2008-11-04 16:24         ` [PATCH 4/5] git send-email: ask less questions when --compose is used Pierre Habouzit
2008-11-04 16:24           ` [PATCH 5/5] git send-email: turn --compose on when more than one patch Pierre Habouzit
2008-11-04 23:54             ` Junio C Hamano
2008-11-05  3:31               ` Jeff King
2008-11-05  7:03                 ` Junio C Hamano
2008-11-05 10:40                   ` [PATCH 2/5] git send-email: interpret unknown files as revision lists Pierre Habouzit
2008-11-05 15:17                     ` Junio C Hamano
2008-11-09 18:56                     ` Junio C Hamano
2008-11-04 20:09           ` [PATCH 4/5] git send-email: ask less questions when --compose is used Francis Galiegue
2008-11-04 23:54           ` Junio C Hamano
2008-11-04 23:54       ` [PATCH 2/5] git send-email: interpret unknown files as revision lists Junio C Hamano
2008-11-10 23:53 ` [take 2] git send-email updates Pierre Habouzit
2008-11-10 23:53   ` [PATCH 1/4] git send-email: make the message file name more specific Pierre Habouzit
2008-11-10 23:54     ` [PATCH 2/4] git send-email: interpret unknown files as revision lists Pierre Habouzit
2008-11-10 23:54       ` [PATCH 3/4] git send-email: add --annotate option Pierre Habouzit
2008-11-10 23:54         ` [PATCH 4/4] git send-email: ask less questions when --compose is used Pierre Habouzit
2008-11-12  5:48       ` [PATCH 2/4] git send-email: interpret unknown files as revision lists Junio C Hamano
2008-11-11 20:30   ` [take 2] git send-email updates Junio C Hamano
2008-11-11 22:13     ` Pierre Habouzit
2008-11-12  0:14       ` Junio C Hamano
2008-11-13  0:01         ` Re* " Junio C Hamano
2008-11-15 22:07           ` Pierre Habouzit
2008-11-15 22:05         ` Pierre Habouzit

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 NNTP newsgroup(s).