unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* magit: Previous commit message keeps appearing
@ 2014-08-07 10:56 Florian Lindner
  2014-08-07 11:17 ` Sebastian Wiesner
  2014-08-07 11:20 ` Quanyang Liu
  0 siblings, 2 replies; 4+ messages in thread
From: Florian Lindner @ 2014-08-07 10:56 UTC (permalink / raw)
  To: help-gnu-emacs

Hello,

from magit-status I use s to stage a couple of files, then "c c" to commit. 
In another buffer I can edit the commit message. What puzzles me, is why 
magit shows the commit message of the previous commit including the file 
list.

Is this by design, some bug or am I wrong?

Emacs 24.3, magit from melpa.

Thanks,
Florian




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

* Re: magit: Previous commit message keeps appearing
  2014-08-07 10:56 magit: Previous commit message keeps appearing Florian Lindner
@ 2014-08-07 11:17 ` Sebastian Wiesner
  2014-08-07 11:20 ` Quanyang Liu
  1 sibling, 0 replies; 4+ messages in thread
From: Sebastian Wiesner @ 2014-08-07 11:17 UTC (permalink / raw)
  To: help-gnu-emacs

Am Donnerstag, 7. August 2014, 12:56:59 schrieb Florian Lindner:
> Hello,
> 
> from magit-status I use s to stage a couple of files, then "c c" to commit.
> In another buffer I can edit the commit message. What puzzles me, is why
> magit shows the commit message of the previous commit including the file
> list.

Magit simply visits 	the COMMIT_EDITMSG file in .git/ when you make a commit.  
Presumably, the buffer for this file wasn't killed after your previous commit, 
and you don't have auto-revert-mode on.  Hence, the next commit would just 
bring the existing COMMIT_EDITMSG buffer up again, with the old contents, like 
if you re-visit a file again.

COMMIT_EDITMSG will have the right contents though, so M-x revert-buffer will 
update the buffer accordingly.





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

* Re: magit: Previous commit message keeps appearing
  2014-08-07 10:56 magit: Previous commit message keeps appearing Florian Lindner
  2014-08-07 11:17 ` Sebastian Wiesner
@ 2014-08-07 11:20 ` Quanyang Liu
  2014-08-07 17:01   ` Florian Lindner
  1 sibling, 1 reply; 4+ messages in thread
From: Quanyang Liu @ 2014-08-07 11:20 UTC (permalink / raw)
  To: help-gnu-emacs

On 08/07/2014 06:56 PM, Florian Lindner wrote:
> Hello,
>
> from magit-status I use s to stage a couple of files, then "c c" to commit.
> In another buffer I can edit the commit message. What puzzles me, is why
> magit shows the commit message of the previous commit including the file
> list.
>
> Is this by design, some bug or am I wrong?
>
> Emacs 24.3, magit from melpa.
>
> Thanks,
> Florian
>
>
I have not seen that... Does it happen every time you commit?

-- 
Quanyang Liu (刘全阳)
Undergraduate
Department of Computer Science and Engineering
Shanghai Jiao Tong University
E-mail:lqymgt@gmail.com



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

* Re: magit: Previous commit message keeps appearing
  2014-08-07 11:20 ` Quanyang Liu
@ 2014-08-07 17:01   ` Florian Lindner
  0 siblings, 0 replies; 4+ messages in thread
From: Florian Lindner @ 2014-08-07 17:01 UTC (permalink / raw)
  To: help-gnu-emacs

Quanyang Liu wrote:

> On 08/07/2014 06:56 PM, Florian Lindner wrote:
>> Hello,
>>
>> from magit-status I use s to stage a couple of files, then "c c" to
>> commit. In another buffer I can edit the commit message. What puzzles me,
>> is why magit shows the commit message of the previous commit including
>> the file list.
>>
>> Is this by design, some bug or am I wrong?
>>
>> Emacs 24.3, magit from melpa.
>>
>> Thanks,
>> Florian
>>
>>
> I have not seen that... Does it happen every time you commit?

Sebastian has explained it very well. I had a COMMIT_EDITMSG in my .git 
directory. Since I was a kind of scared when this wrong commit message 
appeared I always canceled the commit und the MSG persisted. Now I've 
deleted the COMMIT_EDITMSG and did various successfull commits. It never 
came back.

Regards,
Florian




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

end of thread, other threads:[~2014-08-07 17:01 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-07 10:56 magit: Previous commit message keeps appearing Florian Lindner
2014-08-07 11:17 ` Sebastian Wiesner
2014-08-07 11:20 ` Quanyang Liu
2014-08-07 17:01   ` Florian Lindner

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