On Tue, 11 Nov 2003 20:40:59 -0800, Jim wrote > How can I check out a file on Linux with \r's ? > > As part of a build process I use a SHA1 of the source as part of the > versioning information. The same code on both windows and linux should > generate the same SHA1. > You need to normalize your text prior to calculating the SHA1; simply don't include the line-endings when you calculate the hash. (If you look at the standards documentation, you'll note that text is frequently encoded in some well-defined format for most cryptographic standards; "text file" does not constitute such a format.) Failing that, your only options are to check the files in as binary, to only check the SHA1 on one platform, or calculate the reference hashes twice (once on windows, once on Linux) and consider a match with either to be correct. It's a fact of life that different platforms use different line endings, and client tools expect this.
You could of course also use the cygwin client on Windows and configure it to use text files with UNIX line endings. This was the default at one time. Regards, Geoff _______________________________________________ Info-cvs mailing list [EMAIL PROTECTED] http://mail.gnu.org/mailman/listinfo/info-cvs
