Hi all, Wanted to sent out a notice about a change I plan on making this week regarding how line endings are maintained in some of our OS-specific files (bin/solr, zkcli, etc.).
Previously it's been on committers/contributors individually to put the correct line endings in their files. This has bitten us a few times recently. solr.cmd often ends up missing the CRLF EOLs that it needs, which breaks the code surrounding those edits. See SOLR-13977 for a recent example. To remedy this, I plan on adding a .gitattributes file to normalize EOL's across Solr code. File editing is unchanged. But on certain git commands (add, commit, checkout), git will rewrite the line endings of changed files to match the desired EOL for that file. For most files, this is LF. For Windows specific files, this is CRLF. See https://github.com/apache/lucene-solr/pull/1163/files#diff-c781eab6689a2956b8e2d082fdecbe38 for the specific rules. This change should be entirely invisible to developers, with two caveats: 1. Of necessity, the gitattributes PR also corrects a few files that have the wrong line endings currently. Developers applying old patches that touch one of these files will encounter merge conflicts due to the EOL changes. 2. If developers have incorrect line endings in files unique to a feature branch, and they merge master into that feature branch, they may see unexpected changes in git-status as git normalizes the EOL's in those files. Given how rare incorrect EOLs are (outside of solr.cmd), I expect this change will be invisible to 99% of developers. If anyone has any questions or concerns, let me know or comment on the PR (#1163) directly. I plan on merging the change tomorrow or the day after. Best, Jason --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org For additional commands, e-mail: dev-h...@lucene.apache.org