git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* git-send-email is omitting author and date lines
@ 2007-09-23 22:13 Hanspeter Kunz
  2007-09-23 23:29 ` Junio C Hamano
  0 siblings, 1 reply; 9+ messages in thread
From: Hanspeter Kunz @ 2007-09-23 22:13 UTC (permalink / raw)
  To: git

Hi,

sorry if this is a stupid question, but I'm new to git.

When sending a patch to myself using `git-send-email` I realized that
the lines containing the author and the date (lines 5 and 6 in the patch
file) were not in the sent email.

Is this on purpose? And if so, why?

Thanks,
Hp.

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

* Re: git-send-email is omitting author and date lines
  2007-09-23 22:13 git-send-email is omitting author and date lines Hanspeter Kunz
@ 2007-09-23 23:29 ` Junio C Hamano
  2007-09-23 23:35   ` Hanspeter Kunz
  2007-09-24 11:08   ` martin f krafft
  0 siblings, 2 replies; 9+ messages in thread
From: Junio C Hamano @ 2007-09-23 23:29 UTC (permalink / raw)
  To: Hanspeter Kunz; +Cc: git

Hanspeter Kunz <hp@edelkunz.ch> writes:

> When sending a patch to myself using `git-send-email` I realized that
> the lines containing the author and the date (lines 5 and 6 in the patch
> file) were not in the sent email.

Was the commit authored by yourself?

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

* Re: git-send-email is omitting author and date lines
  2007-09-23 23:29 ` Junio C Hamano
@ 2007-09-23 23:35   ` Hanspeter Kunz
  2007-09-24  0:30     ` Johannes Schindelin
  2007-09-24 11:08   ` martin f krafft
  1 sibling, 1 reply; 9+ messages in thread
From: Hanspeter Kunz @ 2007-09-23 23:35 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: git

On Sun, 2007-09-23 at 16:29 -0700, Junio C Hamano wrote:
> Hanspeter Kunz <hp@edelkunz.ch> writes:
> 
> > When sending a patch to myself using `git-send-email` I realized that
> > the lines containing the author and the date (lines 5 and 6 in the patch
> > file) were not in the sent email.
> 
> Was the commit authored by yourself?

yes. does this make a difference?

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

* Re: git-send-email is omitting author and date lines
  2007-09-23 23:35   ` Hanspeter Kunz
@ 2007-09-24  0:30     ` Johannes Schindelin
  2007-09-24  7:16       ` Hanspeter Kunz
  0 siblings, 1 reply; 9+ messages in thread
From: Johannes Schindelin @ 2007-09-24  0:30 UTC (permalink / raw)
  To: Hanspeter Kunz; +Cc: Junio C Hamano, git

Hi,

On Mon, 24 Sep 2007, Hanspeter Kunz wrote:

> On Sun, 2007-09-23 at 16:29 -0700, Junio C Hamano wrote:
> > Hanspeter Kunz <hp@edelkunz.ch> writes:
> > 
> > > When sending a patch to myself using `git-send-email` I realized that
> > > the lines containing the author and the date (lines 5 and 6 in the patch
> > > file) were not in the sent email.
> > 
> > Was the commit authored by yourself?
> 
> yes. does this make a difference?

Yes, it does.  The author is usually inferred from the sender of the mail, 
and therefore git-send-email strips that information from the message 
(IIRC).

Hth,
Dscho

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

* Re: git-send-email is omitting author and date lines
  2007-09-24  0:30     ` Johannes Schindelin
@ 2007-09-24  7:16       ` Hanspeter Kunz
  0 siblings, 0 replies; 9+ messages in thread
From: Hanspeter Kunz @ 2007-09-24  7:16 UTC (permalink / raw)
  To: Johannes Schindelin; +Cc: Junio C Hamano, git

On Mon, 2007-09-24 at 01:30 +0100, Johannes Schindelin wrote:
> Hi,
> 
> On Mon, 24 Sep 2007, Hanspeter Kunz wrote:
> 
> > On Sun, 2007-09-23 at 16:29 -0700, Junio C Hamano wrote:
> > > Hanspeter Kunz <hp@edelkunz.ch> writes:
> > > 
> > > > When sending a patch to myself using `git-send-email` I realized that
> > > > the lines containing the author and the date (lines 5 and 6 in the patch
> > > > file) were not in the sent email.
> > > 
> > > Was the commit authored by yourself?
> > 
> > yes. does this make a difference?
> 
> Yes, it does.  The author is usually inferred from the sender of the mail, 
> and therefore git-send-email strips that information from the message 
> (IIRC).

Ah, I see. And this applies also to the date, I guess.

Many thanks,
Hp.

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

* Re: git-send-email is omitting author and date lines
  2007-09-23 23:29 ` Junio C Hamano
  2007-09-23 23:35   ` Hanspeter Kunz
@ 2007-09-24 11:08   ` martin f krafft
  2007-09-24 11:10     ` Johannes Schindelin
  1 sibling, 1 reply; 9+ messages in thread
From: martin f krafft @ 2007-09-24 11:08 UTC (permalink / raw)
  To: Junio C Hamano; +Cc: Hanspeter Kunz, git

[-- Attachment #1: Type: text/plain, Size: 1438 bytes --]

also sprach Junio C Hamano <gitster@pobox.com> [2007.09.24.0029 +0100]:
> Was the commit authored by yourself?

Sorry for barking in here, but Hanspeter tried to submit a patch to
me and that's when this issue arose.

Yes, he is the author of the commit, as in: user.name and user.email
are the same for the commit and for the email, and this seems to be
the reason the commit header is left out of the email, causing
git-am to use the RFC822 From header instead:

  - patch by Jane, email sent From Jane: no separate From header
  - patch by Jane, email sent From Joe: separate From Jane header 

But information *does* get lost, namely the date. If I send a patch
by email and it gets merged by the recipient, the date of the commit
will be the date of the email, not the date of original commit, or
when it was merged.

To be honest, I have no real preference on this, but it just seems
strange that out of three dates:

  - original commit
  - email sent
  - commit merged

git-send-email/git-am cause the second to be used, which is the
one that makes the *least* sense IMHO.

-- 
martin;              (greetings from the heart of the sun.)
  \____ echo mailto: !#^."<*>"|tr "<*> mailto:" net@madduck
 
"i dislike arguments of any kind. they are always vulgar, and often
 convincing."
                                                        -- oscar wilde
 
spamtraps: madduck.bogus@madduck.net

[-- Attachment #2: Digital signature (see http://martin-krafft.net/gpg/) --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

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

* Re: git-send-email is omitting author and date lines
  2007-09-24 11:08   ` martin f krafft
@ 2007-09-24 11:10     ` Johannes Schindelin
  2007-09-24 17:30       ` martin f krafft
  0 siblings, 1 reply; 9+ messages in thread
From: Johannes Schindelin @ 2007-09-24 11:10 UTC (permalink / raw)
  To: martin f krafft; +Cc: Junio C Hamano, Hanspeter Kunz, git

Hi,

On Mon, 24 Sep 2007, martin f krafft wrote:

> But information *does* get lost, namely the date. If I send a patch
> by email and it gets merged by the recipient, the date of the commit
> will be the date of the email, not the date of original commit, or
> when it was merged.

And that is perfectly okay, since as far as the public is concerned, this 
is the date of the patch.

Ciao,
Dscho

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

* Re: git-send-email is omitting author and date lines
  2007-09-24 11:10     ` Johannes Schindelin
@ 2007-09-24 17:30       ` martin f krafft
  2007-09-24 18:43         ` Junio C Hamano
  0 siblings, 1 reply; 9+ messages in thread
From: martin f krafft @ 2007-09-24 17:30 UTC (permalink / raw)
  To: Johannes Schindelin, Junio C Hamano, Hanspeter Kunz, git

[-- Attachment #1: Type: text/plain, Size: 599 bytes --]

also sprach Johannes Schindelin <Johannes.Schindelin@gmx.de> [2007.09.24.1210 +0100]:
> And that is perfectly okay, since as far as the public is
> concerned, this is the date of the patch.

If you say so. I don't find this at all convincing.

-- 
martin;              (greetings from the heart of the sun.)
  \____ echo mailto: !#^."<*>"|tr "<*> mailto:" net@madduck
 
"if i am occasionally a little overdressed, i make up for it by being
 always immensely over-educated."
                                                        -- oscar wilde
 
spamtraps: madduck.bogus@madduck.net

[-- Attachment #2: Digital signature (see http://martin-krafft.net/gpg/) --]
[-- Type: application/pgp-signature, Size: 189 bytes --]

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

* Re: git-send-email is omitting author and date lines
  2007-09-24 17:30       ` martin f krafft
@ 2007-09-24 18:43         ` Junio C Hamano
  0 siblings, 0 replies; 9+ messages in thread
From: Junio C Hamano @ 2007-09-24 18:43 UTC (permalink / raw)
  To: martin f krafft; +Cc: Johannes Schindelin, Hanspeter Kunz, git

martin f krafft <madduck@madduck.net> writes:

> also sprach Johannes Schindelin <Johannes.Schindelin@gmx.de> [2007.09.24.1210 +0100]:
>> And that is perfectly okay, since as far as the public is
>> concerned, this is the date of the patch.
>
> If you say so. I don't find this at all convincing.

I think that is the reasoning for the current behaviour of
send-email, but it is not unreasonable to have an option to
always add in-body From: and Date: headers to send-email, with a
blessing from a recent post from Linus to the kernel mailing
list:

	http://article.gmane.org/gmane.linux.kernel/582450

Notice the part he says he appreciates Andrew's practice and
talks about message being further forwarded by somebody else.

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

end of thread, other threads:[~2007-09-24 18:43 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-09-23 22:13 git-send-email is omitting author and date lines Hanspeter Kunz
2007-09-23 23:29 ` Junio C Hamano
2007-09-23 23:35   ` Hanspeter Kunz
2007-09-24  0:30     ` Johannes Schindelin
2007-09-24  7:16       ` Hanspeter Kunz
2007-09-24 11:08   ` martin f krafft
2007-09-24 11:10     ` Johannes Schindelin
2007-09-24 17:30       ` martin f krafft
2007-09-24 18:43         ` Junio C Hamano

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).