std.file.readText() extra Line Feed character

Colin via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Fri Dec 19 02:22:01 PST 2014


On Thursday, 18 December 2014 at 22:29:30 UTC, Ali Çehreli wrote:
> On 12/18/2014 02:51 AM, Colin wrote:
>
> > > vi, and it does indeed have a '\n' at the end of file.
> >
> > Ah, I see. That's a little annoying.
>
> It looks like there are ways of dealing with it:
>
>
> http://stackoverflow.com/questions/1050640/vim-disable-automatic-newline-at-end-of-file
>
> Ali
> "happy with Emacs :p"

Does emacs do this aswell? :)

Anyway, I'm making a tool which will be in use by a range of
people, so making the tool accept inputs with \n or not would be
the better choice than getting everyone to ensure they dont have
\n at the end of every file.


More information about the Digitalmars-d-learn mailing list