From: Jonathan Nieder <jrnieder@gmail.com>
To: Eyvind Bernhardsen <eyvind.bernhardsen@gmail.com>
Cc: Junio C Hamano <gitster@pobox.com>,
git@vger.kernel.org,
Johannes Schindelin <johannes.schindelin@gmx.de>,
Johannes Sixt <j6t@kdbg.org>
Subject: [PATCH master] convert: The native line-ending is \r\n on MinGW
Date: Sat, 4 Sep 2010 03:25:09 -0500 [thread overview]
Message-ID: <20100904082509.GC10140@burratino> (raw)
In-Reply-To: <1275679748-7214-1-git-send-email-eyvind.bernhardsen@gmail.com>
If you try this:
1. Install Git for Windows (from the msysgit project)
2. Put
[core]
autocrlf = false
eol = native
in your .gitconfig.
3. Clone a project with
*.txt text
in its .gitattributes.
Then with current git, any text files checked out have LF line
endings, instead of the expected CRLF.
Cc: Johannes Schindelin <johannes.schindelin@gmx.de>
Cc: Johannes Sixt <j6t@kdbg.org>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
Eyvind Bernhardsen wrote:
> Introduce a new configuration variable, "core.eol", that allows the user
> to set which line endings to use for end-of-line-normalized files in the
> working directory. It defaults to "native", which means CRLF on Windows
> and LF everywhere else.
The following fixup has been sitting in my tree (but not tested on
Windows) for a couple of weeks. Sensible?
I don't know what the right choice for Cygwin is; probably LF unless
there is some way to detect the systemwide setting at run time.
Makefile | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/Makefile b/Makefile
index 40fbcae..ba08051 100644
--- a/Makefile
+++ b/Makefile
@@ -1125,6 +1125,7 @@ ifneq (,$(findstring MINGW,$(uname_S)))
compat/win32/pthread.o
EXTLIBS += -lws2_32
PTHREAD_LIBS =
+ NATIVE_CRLF = YesPlease
X = .exe
ifneq (,$(wildcard ../THIS_IS_MSYSGIT))
htmldir=doc/git/html/
--
1.7.2.3
next prev parent reply other threads:[~2010-09-04 8:27 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-06-04 19:29 [PATCH v6] Add "core.eol" config variable Eyvind Bernhardsen
2010-09-04 8:25 ` Jonathan Nieder [this message]
2010-09-07 0:29 ` [PATCH master] convert: The native line-ending is \r\n on MinGW Junio C Hamano
2010-09-25 17:14 ` Ramsay Jones
2012-11-25 15:39 ` Mr_and_Mrs_D
2013-04-15 20:11 ` Brice Lambson
2013-08-13 17:44 ` Tvangeste
2013-08-13 18:03 ` Junio C Hamano
2013-04-15 21:00 ` Junio C Hamano
2013-04-15 21:20 ` Erik Faye-Lund
2013-04-15 21:43 ` Junio C Hamano
2013-04-16 14:39 ` Erik Faye-Lund
2013-04-16 18:03 ` Johannes Sixt
2013-04-16 18:26 ` Junio C Hamano
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: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100904082509.GC10140@burratino \
--to=jrnieder@gmail.com \
--cc=eyvind.bernhardsen@gmail.com \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=j6t@kdbg.org \
--cc=johannes.schindelin@gmx.de \
/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 public inbox
https://80x24.org/mirrors/git.git
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).