You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Kees Kuip <ke...@xs4all.nl> on 2005/11/27 10:55:30 UTC

line-endings of conflict-markers.

We decided to adapt microsoft line-endings (CR-LF) throughout our whole 
sourcecode. We develop on linux and on windows and now we are able to 
copy svn-directories between the 2 operating systems.

But now I have a problem on linux. If svn decides that there is a 
merge-confict it inserts conflict-markers (>>>>>, <<<<<<). But these 
conflict markers have line endings from the native system. So in case of 
linux the line-endings are LF. These files with mixed line endings are 
difficult to edit! vim for instance assumes that if there is only one 
line that ends with LF that the fileformat must be unix. And then I have 
the ^M problem (CR is shown as ^M). If I then save it I have CR-LF-LF in 
  my file.

My request would be that svn inserts conflict-markers which respects the 
line-endings of the original document.

Any thoughts on this (before I submit it as a bug)

Kees.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: line-endings of conflict-markers.

Posted by Duncan Murdoch <su...@murdoch-sutherland.com>.
On 11/27/2005 5:55 AM, Kees Kuip wrote:
> We decided to adapt microsoft line-endings (CR-LF) throughout our whole 
> sourcecode. We develop on linux and on windows and now we are able to 
> copy svn-directories between the 2 operating systems.

This isn't much help, but I've found that Windows programs aimed at 
developers tend to be more flexible than Unix ones in this regard, so I 
do all my development using Unix conventions, even though I work mainly 
on Windows.

I haven't noticed that the conflict markers are messed up, but maybe 
it's just that my editor (textpad) can cope with the problems.

Duncan Murdoch

> 
> But now I have a problem on linux. If svn decides that there is a 
> merge-confict it inserts conflict-markers (>>>>>, <<<<<<). But these 
> conflict markers have line endings from the native system. So in case of 
> linux the line-endings are LF. These files with mixed line endings are 
> difficult to edit! vim for instance assumes that if there is only one 
> line that ends with LF that the fileformat must be unix. And then I have 
> the ^M problem (CR is shown as ^M). If I then save it I have CR-LF-LF in 
>   my file.
> 
> My request would be that svn inserts conflict-markers which respects the 
> line-endings of the original document.
> 
> Any thoughts on this (before I submit it as a bug)
> 
> Kees.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: line-endings of conflict-markers.

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Nov 27, 2005, at 11:55, Kees Kuip wrote:

> We decided to adapt microsoft line-endings (CR-LF) throughout our  
> whole sourcecode. We develop on linux and on windows and now we are  
> able to copy svn-directories between the 2 operating systems.
>
> But now I have a problem on linux. If svn decides that there is a  
> merge-confict it inserts conflict-markers (>>>>>, <<<<<<). But  
> these conflict markers have line endings from the native system. So  
> in case of linux the line-endings are LF. These files with mixed  
> line endings are difficult to edit! vim for instance assumes that  
> if there is only one line that ends with LF that the fileformat  
> must be unix. And then I have the ^M problem (CR is shown as ^M).  
> If I then save it I have CR-LF-LF in  my file.

It has already been submitted.

http://subversion.tigris.org/issues/show_bug.cgi?id=1325

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: line-endings of conflict-markers.

Posted by Ryan Schmidt <su...@ryandesign.com>.
On Nov 28, 2005, at 16:27, Paul Koning wrote:

>> We decided to adapt microsoft line-endings (CR-LF) throughout
>> our whole sourcecode. We develop on linux and on windows and
>> now we are able to copy svn-directories between the 2 operating
>> systems.
>
> That seems very strange.  If you set the line ending to native, you
> can check out on either side without trouble.

That's not strange. We have a Linux web and file server and mostly  
Windows workstations. We might check something out onto a Samba share  
using TortoiseSVN on a Windows machine and then use it from the Linux  
commandline, or we might check it out on the Linux commandline and  
later use it on a Windows client. "Native" line endings are useless  
in this scenario as they're native to the platform that did the  
checkout, which is not necessarily the platform now wanting to edit  
the working copy.


> Even if you want to check out on one system and just copy the
> directory, Unix line endings are the better answer -- with the
> exception of Windows-specific files like MSVC++ project files.

I agree: Unix line endings would be a better choice, and it's what  
we've standardized on in our company. But perhaps that's only because  
a good Windows editor can deal with files with Unix line endings,  
while Unix/Linux commandline utilities in my experience cannot.




---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org

Re: line-endings of conflict-markers.

Posted by Paul Koning <pk...@equallogic.com>.
>>>>> "Kees" == Kees Kuip <ke...@xs4all.nl> writes:

 Kees> We decided to adapt microsoft line-endings (CR-LF) throughout
 Kees> our whole sourcecode. We develop on linux and on windows and
 Kees> now we are able to copy svn-directories between the 2 operating
 Kees> systems.

That seems very strange.  If you set the line ending to native, you
can check out on either side without trouble.

Even if you want to check out on one system and just copy the
directory, Unix line endings are the better answer -- with the
exception of Windows-specific files like MSVC++ project files.

	  paul


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org