git-svn does not seems to work with crlf convertion enabled.

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Alexander Litvinov
Date: Wednesday, July 23, 2008 - 1:44 am

Hello list.

In short: I can't clone svn repo into git when crlf convertion is activated.

Long story.
I use latest git: 
$ git version
git version 1.5.6.4

For a long period of time I use git at work. Main repo is svn-powered and I 
use git-svn for linking git and svn. The project itself is a windows cpp 
project. I use git under Linux machine (Debian etch with manually backported 
git from sid) and work with linux-hosted project thru samba. From the begin I 
did not enable crlf convertion and broke crlf notation in files one by one 
during my commits. My co-workers does not like this and finally I decide to 
try to use autocrlf feature of git. So I take a copy of my git repo and 
convert all text files to unix LF line endings:

git filter-branch --tree-filter "find -type f \( -iname '*.h' -or \
-iname '*.cpp' -or -iname '*.vcproj' -or -iname '*.sln' -or \
-iname '*.h.tmpl' -or -iname '*.bat' -or -iname '*.mp' -or \
-iname '*.txt' -or -iname '*.nsi' -or -iname '*.def' -or \
-iname '*.rc' -or -iname '*.ini' -or -iname '*.inf' -or \
-iname '*.skin' -or -iname '*.c' -or -iname '*.dsp' \
-or -iname '*.dsw' \) -print0 | xargs -r0 dos2unix" \
`git branch -a | sed 's/^..//'`

It finished succefully. After fish I have added  .git/info/attributes like 
this:
*               -crlf
*.h             crlf
*.c             crlf
*.cpp           crlf
and so on...
and add set core.autocrlf to true and safecrlf to false. Also I cleared all 
git-svn's caches:
rm -rf .git/svn

As I understand I got pure repo that is capable to work with crlf convertion. 
Lets update it (on branch forked from trunk): git svn rebase
<.. some long list of revs during migration to new git-svn layout..>
Done rebuilding .git/svn/trunk/.rev_map.f1f59411-8b2e-0410-9ee3-aa470c928bf2
        M       FindHistory.cpp
Incomplete data: Delta source ended unexpectedly at /tmp/g/bin/git-svn line 
3856

Oops ! Whats this ? I am not able to update. I can update other branches but 
not trunk.

So I have to try my old original repo without crlf convertion enabled. It was 
updated succeffuly, I cant show log it was lost and I was not able to 
reproduce it.



Is there any way to fix this problem ?

P.S. I can't even clone that svn repo from scratch with crlf convertion 
enabled.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
git-svn does not seems to work with crlf convertion enabled., Alexander Litvinov, (Wed Jul 23, 1:44 am)
Re: git-svn does not seems to work with crlf convertion en ..., Johannes Schindelin, (Wed Jul 23, 2:18 am)
Re: git-svn does not seems to work with crlf convertion en ..., Alexander Litvinov, (Wed Jul 23, 4:52 am)
Re: git-svn does not seems to work with crlf convertion en ..., Johannes Schindelin, (Wed Jul 23, 5:57 am)
Re: git-svn does not seems to work with crlf convertion en ..., Johannes Schindelin, (Wed Jul 23, 9:07 am)
Re: git-svn does not seems to work with crlf convertion en ..., Alexander Litvinov, (Wed Jul 23, 8:13 pm)
Re: git-svn does not seems to work with crlf convertion en ..., Johannes Schindelin, (Thu Jul 24, 7:40 am)
Re: git-svn does not seems to work with crlf convertion en ..., Alexander Litvinov, (Tue Jul 29, 9:37 pm)
[PATCH] git-svn now work with crlf convertion enabled., Alexander Litvinov, (Wed Jul 30, 10:43 pm)
Re: [PATCH] git-svn now work with crlf convertion enabled., Alexander Litvinov, (Wed Jul 30, 10:57 pm)
Re: [PATCH] git-svn now work with crlf convertion enabled., Dmitry Potapov, (Thu Jul 31, 3:45 am)
[RFC] hash-object --no-filters, Dmitry Potapov, (Thu Jul 31, 12:09 pm)
Re: [PATCH] git-svn now work with crlf convertion enabled., Alexander Litvinov, (Thu Jul 31, 8:23 pm)
Re: [PATCH] git-svn now work with crlf convertion enabled., Junio C Hamano, (Thu Jul 31, 10:09 pm)
Re: [PATCH] git-svn now work with crlf convertion enabled., Dmitry Potapov, (Fri Aug 1, 12:44 am)
Re: [PATCH] git-svn now work with crlf convertion enabled., Dmitry Potapov, (Fri Aug 1, 12:47 am)
Re: [PATCH] git-svn now work with crlf convertion enabled., Alexander Litvinov, (Fri Aug 1, 4:11 am)
Re: [PATCH] git-svn now work with crlf convertion enabled., Alexander Litvinov, (Fri Aug 1, 4:27 am)
Re: [PATCH] git-svn now work with crlf convertion enabled., Alexander Litvinov, (Sun Aug 3, 8:10 pm)
Re: git-svn does not seems to work with crlf convertion en ..., Johannes Schindelin, (Wed Aug 6, 5:43 am)