From: Stefan Monnier <monnier@iro.umontreal.ca>
To: help-gnu-emacs@gnu.org
Subject: Re: How to see the raw line endings in a file?
Date: Sun, 31 Mar 2019 16:08:39 -0400 [thread overview]
Message-ID: <jwvwokeyfkk.fsf-monnier+emacs@gnu.org> (raw)
In-Reply-To: 86wokfgd8e.fsf@dod.no
>> Emacs never hides CRLF EOLs unless it says "DOS" in the mode line. If
>> your file has mixed EOL format, then either you will see "DOS" in the
>> mode line or some of the lines will have ^M characters at their end.
>
> This is what I have been trusting to be happening for many years.
> 1. I see no "DOS" in the mode line before running the commands
> 2. I see a mix of lines with and without ^M after running the commands
So your input file is using Unix line-endings and apparently the command
you run copies some of the input with those (LF) line-endings to the
output and also outputs some of its own text with its own (CRLF)
line-endings line-endings, hence a mix of the two in the output.
You can probably circumvent the problem either by tweaking the command
so that it uses LF line-endings for its own text, or changing the input
so that it uses CRLF line-endings.
Stefan
next prev parent reply other threads:[~2019-03-31 20:08 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-03-31 16:47 How to see the raw line endings in a file? Steinar Bang
2019-03-31 17:18 ` Eli Zaretskii
2019-03-31 17:33 ` Steinar Bang
2019-03-31 17:44 ` Eli Zaretskii
2019-03-31 18:57 ` Steinar Bang
2019-03-31 19:09 ` Steinar Bang
2019-03-31 20:17 ` Eli Zaretskii
2019-03-31 19:10 ` Eli Zaretskii
2019-03-31 20:08 ` Stefan Monnier [this message]
2019-03-31 19:20 ` Drew Adams
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=jwvwokeyfkk.fsf-monnier+emacs@gnu.org \
--to=monnier@iro.umontreal.ca \
--cc=help-gnu-emacs@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).