GNU bug report logs - #7497
problem about auto adding newline at the end of file

Previous Next

Package: emacs;

Reported by: 李银璠 <linfeixb27 <at> gmail.com>

Date: Sat, 27 Nov 2010 10:50:03 UTC

Severity: normal

Done: Eli Zaretskii <eliz <at> gnu.org>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 7497 in the body.
You can then email your comments to 7497 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7497; Package emacs. (Sat, 27 Nov 2010 10:50:03 GMT) Full text and rfc822 format available.

Acknowledgement sent to 李银璠 <linfeixb27 <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-gnu-emacs <at> gnu.org. (Sat, 27 Nov 2010 10:50:03 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: 李银璠 <linfeixb27 <at> gmail.com>
To: bug-gnu-emacs <at> gnu.org
Subject: problem about auto adding newline at the end of file
Date: Sat, 27 Nov 2010 18:53:17 +0800
[Message part 1 (text/plain, inline)]
My emacs does not behave as stated in the documentation,
http://www.gnu.org/software/emacs/manual/html_node/emacs/Customize-Save.html#Customize-Save
.

In the documentation, it is said that, if require-final-newline is set to
nil, no changes would be adapted to my files, leaving them not ended with
newline (0x0d0a).
My emacs, on the other hand, always adds newline at the end of file,
automatically, even when I add (setq-default require-final-newline nil); or
(setq require-final-newline nil);to .emacs. (I tried them both)

I don't know if it is a bug, or it is caused by my wrong operation. I'm
using Ubuntu 10.10, emacs 23.1.1
[Message part 2 (text/html, inline)]

Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7497; Package emacs. (Sat, 27 Nov 2010 12:25:02 GMT) Full text and rfc822 format available.

Message #8 received at 7497 <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: 李银璠 <linfeixb27 <at> gmail.com>
Cc: 7497 <at> debbugs.gnu.org
Subject: Re: bug#7497: problem about auto adding newline at the end of file
Date: Sat, 27 Nov 2010 14:31:38 +0200
> Date: Sat, 27 Nov 2010 18:53:17 +0800
> From: 李银璠 <linfeixb27 <at> gmail.com>
> Cc: 
> 
> My emacs does not behave as stated in the documentation,
> http://www.gnu.org/software/emacs/manual/html_node/emacs/Customize-Save.html#Customize-Save
> .
> 
> In the documentation, it is said that, if require-final-newline is set to
> nil, no changes would be adapted to my files, leaving them not ended with
> newline (0x0d0a).
> My emacs, on the other hand, always adds newline at the end of file,
> automatically, even when I add (setq-default require-final-newline nil); or
> (setq require-final-newline nil);to .emacs. (I tried them both)
> 
> I don't know if it is a bug, or it is caused by my wrong operation. I'm
> using Ubuntu 10.10, emacs 23.1.1

I cannot reproduce this in Emacs 23.1.  Please show a complete recipe,
starting with "emacs -Q", to reproduce this problem.

One possibility is that you see this in a file that turns a major mode
which uses mode-require-final-newline to set the buffer-local value of
require-final-newline.  In that case, you may wish to customize
mode-require-final-newline, or maybe reset require-final-newline in a
mode hook.





Information forwarded to owner <at> debbugs.gnu.org, bug-gnu-emacs <at> gnu.org:
bug#7497; Package emacs. (Fri, 03 Dec 2010 06:22:01 GMT) Full text and rfc822 format available.

Message #11 received at 7497 <at> debbugs.gnu.org (full text, mbox):

From: 李银璠 <linfeixb27 <at> gmail.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 7497 <at> debbugs.gnu.org
Subject: Re: bug#7497: problem about auto adding newline at the end of file
Date: Fri, 3 Dec 2010 14:27:36 +0800
[Message part 1 (text/plain, inline)]
Dear sir/lady,
I have fixed my problem. It turned out to be no bug.
It was a major mode that use mode-require-final-newline. Thank you very much
for your instructions. I used almost one week to understand the instructions
(I was quite new to emacs).
Sorry if I wasted your time.

On Sat, Nov 27, 2010 at 8:31 PM, Eli Zaretskii <eliz <at> gnu.org> wrote:

> > Date: Sat, 27 Nov 2010 18:53:17 +0800
> > From: 李银璠 <linfeixb27 <at> gmail.com>
> > Cc:
> >
> > My emacs does not behave as stated in the documentation,
> >
> http://www.gnu.org/software/emacs/manual/html_node/emacs/Customize-Save.html#Customize-Save
> > .
> >
> > In the documentation, it is said that, if require-final-newline is set to
> > nil, no changes would be adapted to my files, leaving them not ended with
> > newline (0x0d0a).
> > My emacs, on the other hand, always adds newline at the end of file,
> > automatically, even when I add (setq-default require-final-newline nil);
> or
> > (setq require-final-newline nil);to .emacs. (I tried them both)
> >
> > I don't know if it is a bug, or it is caused by my wrong operation. I'm
> > using Ubuntu 10.10, emacs 23.1.1
>
> I cannot reproduce this in Emacs 23.1.  Please show a complete recipe,
> starting with "emacs -Q", to reproduce this problem.
>
> One possibility is that you see this in a file that turns a major mode
> which uses mode-require-final-newline to set the buffer-local value of
> require-final-newline.  In that case, you may wish to customize
> mode-require-final-newline, or maybe reset require-final-newline in a
> mode hook.
>
[Message part 2 (text/html, inline)]

Reply sent to Eli Zaretskii <eliz <at> gnu.org>:
You have taken responsibility. (Fri, 03 Dec 2010 10:42:01 GMT) Full text and rfc822 format available.

Notification sent to 李银璠 <linfeixb27 <at> gmail.com>:
bug acknowledged by developer. (Fri, 03 Dec 2010 10:42:02 GMT) Full text and rfc822 format available.

Message #16 received at 7497-done <at> debbugs.gnu.org (full text, mbox):

From: Eli Zaretskii <eliz <at> gnu.org>
To: 李银璠 <linfeixb27 <at> gmail.com>
Cc: 7497-done <at> debbugs.gnu.org
Subject: Re: bug#7497: problem about auto adding newline at the end of file
Date: Fri, 03 Dec 2010 12:47:10 +0200
> Date: Fri, 3 Dec 2010 14:27:36 +0800
> From: 李银璠 <linfeixb27 <at> gmail.com>
> Cc: 7497 <at> debbugs.gnu.org
> 
> Dear sir/lady,
> I have fixed my problem. It turned out to be no bug.
> It was a major mode that use mode-require-final-newline. Thank you very much
> for your instructions. I used almost one week to understand the instructions
> (I was quite new to emacs).

Thanks, I'm closing the bug report.





bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 31 Dec 2010 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 14 years and 232 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.