You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by "Stefan Bodewig (Created) (JIRA)" <ji...@apache.org> on 2011/11/03 12:25:33 UTC
[Lucene.Net] [jira] [Created] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Many files need proper svn properties to set the linefeeds
----------------------------------------------------------
Key: LUCENENET-453
URL: https://issues.apache.org/jira/browse/LUCENENET-453
Project: Lucene.Net
Issue Type: Bug
Reporter: Stefan Bodewig
Priority: Minor
Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
Some files have inconsistent linefeeds, I'll attach a patch.
Some files even have bad mine-types. You need to run
svn pd svn:mime-type
on
test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
Re: [Lucene.Net] [jira] [Commented] (LUCENENET-453) Many files need
proper svn properties to set the linefeeds
Posted by Michael Herndon <mh...@wickedsoftware.net>.
Just in case anyone else following this that are still fuzzy on the details
due to the acronyms.
CRLF is the windows version of a new line. "\r\n" carriage return,line
feed. or in c# Environment.NewLine;
eol = end of line.
eof = end of file.
FOSS projects that will possibly run on multiple platforms generally have
to be more aware of this than others.
http://en.wikipedia.org/wiki/Newline
I sometimes forget about this kind of thing myself. but scm generally has
ways to checkout in one format and commit back in the other. I know that
git has options for this.
You might get notices from visual studio about switching the line breaks to
crlf if the file is not in that format. text-editor behavior varies.
On Sun, Nov 13, 2011 at 2:25 AM, Stefan Bodewig (Commented) (JIRA) <
jira@apache.org> wrote:
>
> [
> https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13149241#comment-13149241]
>
> Stefan Bodewig commented on LUCENENET-453:
> ------------------------------------------
>
> Basically I did something like
>
> find . -name \*.cs -print0 | xargs -0 -e svn ps svn:eol-style native
>
> i.e. I set the eol-style to native for all C# sources and then used "svn
> status" to see which ones didn't have that already. Repeat for the other
> file types I expected to have bad line-ends. Another approach would be to
> run Ant's fixcrlf task over the tree and see what gets changed. I'm sure
> there are other ways to do this.
>
> svn will complain if you try to set the svn:eol-style property on a file
> with a binary MIME type. When I started to write the comment I expected to
> find more files than the one, that's why it reads a bit weird. Yes, AFAIR
> this was the only binary source file.
>
> svn tracks line-feed information in the svn:eol-style property. By
> default it doesn't do any transformations at all. If you set it to native
> then all line-feeds will be transformed when checking out files (I think
> svn uses \n internally) to your platform's default and back on commit.
> Apart from native there are explicit values for "always \n" and so on.
> You use that for files that are only meaningful on specific platforms
> (shell scripts and batch files, mostly). build.cmd is Windows only so it
> makes sense to set the property to "CRLF".
>
> See
> http://svnbook.red-bean.com/en/1.7/svn.advanced.props.file-portability.html#svn.advanced.props.special.eol-style
>
> > Many files need proper svn properties to set the linefeeds
> > ----------------------------------------------------------
> >
> > Key: LUCENENET-453
> > URL: https://issues.apache.org/jira/browse/LUCENENET-453
> > Project: Lucene.Net
> > Issue Type: Bug
> > Reporter: Stefan Bodewig
> > Priority: Minor
> > Attachments: LUCENENET-453.inconsistent-eol.patch,
> LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
> >
> >
> > Many files are lacking the svn:eol-style proper which should be set to
> native, I'll attach a list later.
> > Some files have inconsistent linefeeds, I'll attach a patch.
> > Some files even have bad mine-types. You need to run
> > svn pd svn:mime-type
> > on
> > test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> > build.cmd should likely get an svn:eol-style of crlf
>
> --
> This message is automatically generated by JIRA.
> If you think it was sent incorrectly, please contact your JIRA
> administrators:
> https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
> For more information on JIRA, see: http://www.atlassian.com/software/jira
>
>
>
[Lucene.Net] [jira] [Closed] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Posted by "Prescott Nasser (Closed) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Prescott Nasser closed LUCENENET-453.
-------------------------------------
> Many files need proper svn properties to set the linefeeds
> ----------------------------------------------------------
>
> Key: LUCENENET-453
> URL: https://issues.apache.org/jira/browse/LUCENENET-453
> Project: Lucene.Net
> Issue Type: Bug
> Reporter: Stefan Bodewig
> Assignee: Prescott Nasser
> Priority: Minor
> Fix For: Lucene.Net 2.9.4
>
> Attachments: LUCENENET-453.inconsistent-eol.patch, LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
>
>
> Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
> Some files have inconsistent linefeeds, I'll attach a patch.
> Some files even have bad mine-types. You need to run
> svn pd svn:mime-type
> on
> test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[Lucene.Net] [jira] [Updated] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Posted by "Stefan Bodewig (Updated) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stefan Bodewig updated LUCENENET-453:
-------------------------------------
Attachment: LUCENENET-453.inconsistent-eol.patch
patch that fixes inconsistent linefeeds
> Many files need proper svn properties to set the linefeeds
> ----------------------------------------------------------
>
> Key: LUCENENET-453
> URL: https://issues.apache.org/jira/browse/LUCENENET-453
> Project: Lucene.Net
> Issue Type: Bug
> Reporter: Stefan Bodewig
> Priority: Minor
> Attachments: LUCENENET-453.inconsistent-eol.patch
>
>
> Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
> Some files have inconsistent linefeeds, I'll attach a patch.
> Some files even have bad mine-types. You need to run
> svn pd svn:mime-type
> on
> test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[Lucene.Net] [jira] [Resolved] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Posted by "Prescott Nasser (Resolved) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Prescott Nasser resolved LUCENENET-453.
---------------------------------------
Resolution: Fixed
Fix Version/s: Lucene.Net 2.9.4
Assignee: Prescott Nasser
Committed
> Many files need proper svn properties to set the linefeeds
> ----------------------------------------------------------
>
> Key: LUCENENET-453
> URL: https://issues.apache.org/jira/browse/LUCENENET-453
> Project: Lucene.Net
> Issue Type: Bug
> Reporter: Stefan Bodewig
> Assignee: Prescott Nasser
> Priority: Minor
> Fix For: Lucene.Net 2.9.4
>
> Attachments: LUCENENET-453.inconsistent-eol.patch, LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
>
>
> Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
> Some files have inconsistent linefeeds, I'll attach a patch.
> Some files even have bad mine-types. You need to run
> svn pd svn:mime-type
> on
> test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[Lucene.Net] [jira] [Updated] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Posted by "Stefan Bodewig (Updated) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Stefan Bodewig updated LUCENENET-453:
-------------------------------------
Attachment: LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
list of files that need their svn:eol-style property set to native
> Many files need proper svn properties to set the linefeeds
> ----------------------------------------------------------
>
> Key: LUCENENET-453
> URL: https://issues.apache.org/jira/browse/LUCENENET-453
> Project: Lucene.Net
> Issue Type: Bug
> Reporter: Stefan Bodewig
> Priority: Minor
> Attachments: LUCENENET-453.inconsistent-eol.patch, LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
>
>
> Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
> Some files have inconsistent linefeeds, I'll attach a patch.
> Some files even have bad mine-types. You need to run
> svn pd svn:mime-type
> on
> test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[Lucene.Net] [jira] [Commented] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Posted by "Prescott Nasser (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13149204#comment-13149204 ]
Prescott Nasser commented on LUCENENET-453:
-------------------------------------------
Hey Stefan is test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs the only file with the bad mime-type? Also, how do you run a scan on all files for something like this? I have no idea now that works.
Also for 'build.cmd should likely get an svn:eol-style of crlf' what does that mean exactly? (Sorry out of my depth here)
> Many files need proper svn properties to set the linefeeds
> ----------------------------------------------------------
>
> Key: LUCENENET-453
> URL: https://issues.apache.org/jira/browse/LUCENENET-453
> Project: Lucene.Net
> Issue Type: Bug
> Reporter: Stefan Bodewig
> Priority: Minor
> Attachments: LUCENENET-453.inconsistent-eol.patch, LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
>
>
> Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
> Some files have inconsistent linefeeds, I'll attach a patch.
> Some files even have bad mine-types. You need to run
> svn pd svn:mime-type
> on
> test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[Lucene.Net] [jira] [Commented] (LUCENENET-453) Many files need proper svn
properties to set the linefeeds
Posted by "Stefan Bodewig (Commented) (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/LUCENENET-453?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13149241#comment-13149241 ]
Stefan Bodewig commented on LUCENENET-453:
------------------------------------------
Basically I did something like
find . -name \*.cs -print0 | xargs -0 -e svn ps svn:eol-style native
i.e. I set the eol-style to native for all C# sources and then used "svn status" to see which ones didn't have that already. Repeat for the other file types I expected to have bad line-ends. Another approach would be to run Ant's fixcrlf task over the tree and see what gets changed. I'm sure there are other ways to do this.
svn will complain if you try to set the svn:eol-style property on a file with a binary MIME type. When I started to write the comment I expected to find more files than the one, that's why it reads a bit weird. Yes, AFAIR this was the only binary source file.
svn tracks line-feed information in the svn:eol-style property. By default it doesn't do any transformations at all. If you set it to native then all line-feeds will be transformed when checking out files (I think svn uses \n internally) to your platform's default and back on commit. Apart from native there are explicit values for "always \n" and so on. You use that for files that are only meaningful on specific platforms (shell scripts and batch files, mostly). build.cmd is Windows only so it makes sense to set the property to "CRLF".
See http://svnbook.red-bean.com/en/1.7/svn.advanced.props.file-portability.html#svn.advanced.props.special.eol-style
> Many files need proper svn properties to set the linefeeds
> ----------------------------------------------------------
>
> Key: LUCENENET-453
> URL: https://issues.apache.org/jira/browse/LUCENENET-453
> Project: Lucene.Net
> Issue Type: Bug
> Reporter: Stefan Bodewig
> Priority: Minor
> Attachments: LUCENENET-453.inconsistent-eol.patch, LUCENENET-453.list-of-files-with-missing-svn_eol-style.txt
>
>
> Many files are lacking the svn:eol-style proper which should be set to native, I'll attach a list later.
> Some files have inconsistent linefeeds, I'll attach a patch.
> Some files even have bad mine-types. You need to run
> svn pd svn:mime-type
> on
> test/contrib/Core/Analysis/Ext/Analysis.Ext.Test.cs
> build.cmd should likely get an svn:eol-style of crlf
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira