delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2006/09/27/18:57:12

X-Spam-Check-By: sourceware.org
Message-ID: <451B016A.4050104@buddydog.org>
Date: Wed, 27 Sep 2006 18:55:38 -0400
From: Jonathan Arnold <jdarnold AT buddydog DOT org>
User-Agent: Thunderbird 1.5.0.5 (X11/20060804)
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Bash 3.1.17(8) CR/LF problem
References: <860934040609271355n7d60313fjd63fe55711b59706 AT mail DOT gmail DOT com>
In-Reply-To: <860934040609271355n7d60313fjd63fe55711b59706@mail.gmail.com>
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Malcolm Nixon wrote:
> Jonathan Arnold wrote:
>>>      * Some translate files to a "Local" format (CR/LF on Windows).
>> Perforce will do this if you let it.  Or you can set the LineEnd option
>> for the client to be Unix or Share.
> 
> This was in fact my original patch attempt, however it had the following
> problems:
>   * You can only set this option for an entire ClientSpec, not
> individual files.
>   * Some editors (Notepad & Crimson Editor) don't support just LF.
>   * Perforce messes up files on check-in. We haven't tracked down the exact
>     cause yet, but some files modified on systems with LineEnd=unix are
>     being fetched with only LF on systems with LineEnd=local.
> 
> Basically we can't 'infect' a mostly Windows source-tree with LF
> terminated files, whether the LFs are only resident on peoples local
> Windows boxes, or checked in to the Perforce repository.

You can change the Perforce filetype to be binary, and that way Perforce
will leave the cr/lf alone. Then check out the scripts, do a d2u on them,
and check them back in.

$ p4 edit -t binary myscript.sh

-- 
Jonathan Arnold                       http://www.buddydog.org

When cryptography is outlawed, bayl bhgynjf jvyy unir cevinpl.


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019