Re: [webkit-dev] sln files with wrong line endings
On 14/02/2013, at 6:23 pm, Vivek Galatage vivekgalat...@gmail.com wrote: I had the same problem and was able to trace the reason for this. http://stackoverflow.com/questions/1889559/git-diff-to-ignore-m Its the ^M characters at the EOL. git diff --ignore-space-at-eol ignores the change from the diff. Something similar was happening with http://trac.webkit.org/browser/trunk/Source/WTF/WTF.vcproj/WTF.sln and its changelog says it. FWIW, I’ve hit something similar to this when rsyncing repositories between machines. All of a sudden, that WTF.sln file is marked as modified, but git diff can’t see the change. I “fix it by deleting the the .git/index and then doing a git checkout. Dean On Thu, Feb 14, 2013 at 12:40 PM, Christophe Dumez - SISA ch.du...@sisa.samsung.com wrote: Hi, The same thing has just happened to me. I managed to get rid of the changes to this file by doing: git reset --hard Kr, Christope Dumez. From: webkit-dev-boun...@lists.webkit.org [webkit-dev-boun...@lists.webkit.org] on behalf of Eric Seidel [e...@webkit.org] Sent: Thursday, February 14, 2013 08:23 To: WebKit Development Subject: [webkit-dev] sln files with wrong line endings We've had this come up before, but I figure I should ask on webkit-dev to see if we have a solution. :) Right now the Tools/DumpRenderTree/DumpRenderTree.vcxproj/DumpRenderTree.sln file is in some sort of bad state such that my Git checkout can't seem to not-modify the file. I'm not sure if it's a Git bug, or a repository config bug. But it means I can't seem to produce patches w/o modifying this file. :( https://bugs.webkit.org/attachment.cgi?id=188263action=review Thoughts? ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev
Re: [webkit-dev] sln files with wrong line endings
This also happened to me, quite annoying. :-( I've followed the thread https://groups.google.com/a/chromium.org/forum/?fromgroups=#!topic/chromium-dev/YpKL4xiJHPQ and did the following: editing .gitattributes to disable the eol=crlf flag for .sln files, then doing a reset/checkout, then un-editing .gitattributes. On Thu, Feb 14, 2013 at 6:45 AM, John Yani van...@gmail.com wrote: Checkout this link: https://help.github.com/articles/dealing-with-line-endings I don't know what the webkit convention is when dealing with line-endings, but you may want to make sln files to always have crlf line-ending. ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev -- Rafael Brandao @ INdT ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev
Re: [webkit-dev] sln files with wrong line endings
Typically in Subversion the fix for a problem like this is to set the eol-style explicitly; presumably to CRLF for Windows project and solution files and to LF or native for plain old source files. Once that property is set, people changing file later on can’t cause problems with inconsistent line endings, because Subversion will check the line endings at commit time. I have no idea how having git in the mix affects this. In fact, I don’t know how to set a Subversion property using git-svn which means I can’t easily just jump in and fix this like I would have in the past. -- Darin ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev
Re: [webkit-dev] sln files with wrong line endings
I'm pretty sure r142864 fixed this (perhaps unintentionally) by changing all line endings in DumpRenderTree.sln from CRLF to LF. On Thu, Feb 14, 2013 at 11:11 AM, Darin Adler da...@apple.com wrote: Typically in Subversion the fix for a problem like this is to set the eol-style explicitly; presumably to CRLF for Windows project and solution files and to LF or native for plain old source files. Once that property is set, people changing file later on can’t cause problems with inconsistent line endings, because Subversion will check the line endings at commit time. I have no idea how having git in the mix affects this. WebKit's .gitattributes file contains the following: *.vcproj eol=crlf *.vsprops eol=crlf *.sln eol=crlf This tells git, When storing this file in the repository, convert all line endings to LF. When checking out this file to disk, convert all line endings to CRLF. If the committed version of the file in the repository contains CRLF line endings, git will show a diff that converts the CRLF line endings to LF. eol=crlf means that the line endings *in the repository* should be LF, so git is trying to fix it. I think the thing to do is to set svn:eol-style to native for all .vcproj, .vsprops, and .sln files. That way Subversion will commit the files using LF line endings (like git wants), and check them out using CRLF on Windows (like Visual Studio wants). In fact, I don’t know how to set a Subversion property using git-svn which means I can’t easily just jump in and fix this like I would have in the past. I don't think git-svn can set properties. When I've had to change properties in the past I've checked out the appropriate subset of WebKit using Subversion and made my changes there. -Adam ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev
Re: [webkit-dev] sln files with wrong line endings
Hi All, Here is an old bug report about it: Files with CRLF lineendigs without svn:eol-style=native kills git svn repositories https://bugs.webkit.org/show_bug.cgi?id=96934 The general fix would be to force all Windows project file have svn:eol-style=native svn property. git-svn users who commit this files can do it automatically inside: ~/.subversion/config *.vsprops = svn:eol-style=native *.vcproj = svn:eol-style=native But we should force all developers to set it somehow. There is a working solution for png files: https://trac.webkit.org/changeset/122311 It force commit svn:mime-type image/png svn property for SVN users and warn GIT-SVN users if they didn't set their ~/.subversion/config properly. I think a volunteer can do a similar thing for Windows project files. Ossy Adam Roben írta: I'm pretty sure r142864 fixed this (perhaps unintentionally) by changing all line endings in DumpRenderTree.sln from CRLF to LF. On Thu, Feb 14, 2013 at 11:11 AM, Darin Adler da...@apple.com wrote: Typically in Subversion the fix for a problem like this is to set the eol-style explicitly; presumably to CRLF for Windows project and solution files and to LF or native for plain old source files. Once that property is set, people changing file later on can't cause problems with inconsistent line endings, because Subversion will check the line endings at commit time. I have no idea how having git in the mix affects this. WebKit's .gitattributes file contains the following: *.vcproj eol=crlf *.vsprops eol=crlf *.sln eol=crlf This tells git, When storing this file in the repository, convert all line endings to LF. When checking out this file to disk, convert all line endings to CRLF. If the committed version of the file in the repository contains CRLF line endings, git will show a diff that converts the CRLF line endings to LF. eol=crlf means that the line endings *in the repository* should be LF, so git is trying to fix it. I think the thing to do is to set svn:eol-style to native for all .vcproj, .vsprops, and .sln files. That way Subversion will commit the files using LF line endings (like git wants), and check them out using CRLF on Windows (like Visual Studio wants). In fact, I don't know how to set a Subversion property using git-svn which means I can't easily just jump in and fix this like I would have in the past. I don't think git-svn can set properties. When I've had to change properties in the past I've checked out the appropriate subset of WebKit using Subversion and made my changes there. -Adam ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev
Re: [webkit-dev] sln files with wrong line endings
Hi, The same thing has just happened to me. I managed to get rid of the changes to this file by doing: git reset --hard Kr, Christope Dumez. From: webkit-dev-boun...@lists.webkit.org [webkit-dev-boun...@lists.webkit.org] on behalf of Eric Seidel [e...@webkit.org] Sent: Thursday, February 14, 2013 08:23 To: WebKit Development Subject: [webkit-dev] sln files with wrong line endings We've had this come up before, but I figure I should ask on webkit-dev to see if we have a solution. :) Right now the Tools/DumpRenderTree/DumpRenderTree.vcxproj/DumpRenderTree.sln file is in some sort of bad state such that my Git checkout can't seem to not-modify the file. I'm not sure if it's a Git bug, or a repository config bug. But it means I can't seem to produce patches w/o modifying this file. :( https://bugs.webkit.org/attachment.cgi?id=188263action=review Thoughts? ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev ___ webkit-dev mailing list webkit-dev@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-dev