43 | | Internally, Subversion stores all text files using the Unix line endings (i.e., a single line feed). When checking out a text file on a Windows machine, however, we would prefer the file to have Windows-style line endings (i.e., carriage return/line feed pairs). Blindly adding and committing files can lead to inconsistent line endings, causing problems with some tools. Boost adopts an approach using [http://svnbook.red-bean.com/en/1.1/ch07s02.html `svn:eol-style` properties] to provide native line endings for users on all platforms. Each text file in the Boost Subversion repository must have its MIME type set appropriately and have the `svn:eol-style` property set to `native`. These settings will be verified by the Subversion repository itself, to keep the repository consistent. |
| 43 | By default, Subversion treats all files as binary. Thus, a text file checked into Subversion with Unix line endings would retain those Unix line endings even when checked out on a Windows or Mac machine. A text file edited on several machines using different platforms would likely end up with inconsistent line endings, causing problems with various development tools. To address this problem, Boost adopts an approach using [http://svnbook.red-bean.com/en/1.1/ch07s02.html `svn:eol-style` properties] to provide native line endings for users on all platforms. Each text file in the Boost Subversion repository must have its MIME type set appropriately. For each file with a "text/" MIME type, the file must also have the `svn:eol-style` property set to `native`. When the`svn:eol-style` is `native`, the Subversion server stores the file using Unix line endings, but the Subversion client will translate between the server's end-of-line format and the client's native end-of-line format. These settings will be verified by the Subversion repository itself, to keep the repository consistent. Specifically, the Subversion repository will reject commits that contain any files without the `svn:mime-type` property set or any text files without the `svn:eol-style` property set. |