From: Steinar Bang <sb@dod.no>
To: help-gnu-emacs@gnu.org
Subject: Re: How to see the raw line endings in a file?
Date: Sun, 31 Mar 2019 20:57:55 +0200 [thread overview]
Message-ID: <86sgv2hnws.fsf@dod.no> (raw)
In-Reply-To: <83o95rgcq0.fsf@gnu.org> (Eli Zaretskii's message of "Sun, 31 Mar 2019 20:44:55 +0300")
>>>>> Eli Zaretskii <eliz@gnu.org>:
> Then why are you saying that Emacs hides CR characters from you? It
> does show them as those ^Ms.
I'm not saying that emacs hides CR characters from me. I'm asking the
question: is it a possibility that emacs hides characters from me?
(And I see from your reply that the answer to that question is "no")
The reason I'm asking this question is that I am encountering a problem
noone else seems to be encountering, and I was wondering if I could
trust what emacs is telling me (ie. that the files originally were lf
eol only).
(It could be that my google searches are insufficient to find others
with the same problem, but by my experience is that weird problems that
noone else has, is usually caused by a silly problem with my own code or
setup)
> In general, when a file has mixed EOLs, what will show in the mode
> line and what in the buffer is determined by sheer luck, because Emacs
> examines only a small portion of the file to determine the EOL format,
> and depending on where you have CRLF and where just LF you can end up
> with either "DOS" or ^M characters.
Hm... so, if the is not detected as "DOS" and I mainly look at the start
of the file, then it looks like a unix file, but could have an CR
further down...?
Ok, thanks for the info. I will investigate further and report back.
next prev parent reply other threads:[~2019-03-31 18:57 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 [this message]
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
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=86sgv2hnws.fsf@dod.no \
--to=sb@dod.no \
--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.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.