Binary Files
[Previous] [Main] [Next]

Binary Files - non-text Files


Non-text files are not handled as completely as text files. You need to use the CVSWRAPPERS environment variable or file to tell your system which files to treat as non-text files. You can also do this manually when you add a file.

The main things to remember is that you need to turn off "EOL Conversion" and "Keyword Expansion". -kb option turns off both.

Binaries are stored in the same manner as text files on the server even when you tell it the file is binary or tell it to COPY instead of MERGE. The storage method is even done with diffs. These diffs just don't mean anything to us and CVS will not show the diffs to you. If you try to do a CVS DIFF on them you get something like the following:
cvs diff -r1.1 -r1.2 CMS.gif

Index: CMS.gif
===================================================================
RCS file: /usr/local/javadeliver/gplcms/CMS.gif,v
retrieving revision 1.1
retrieving revision 1.2
diff -r1.1 -r1.2
Binary files /tmp/cvsQHHP6V and /tmp/cvsy0ifOH differ

You can retrieve the two different versions with
cvs -p update r1.1 CMS.gif > older.gif
cvs -p update r1.2 CMS.gif > newer.gif