This area is an archive and is no longer actively maintained. Information found on this page is likely to be extremely out of date and therefore highly inaccurate. We recommend the Ximbiot - CVS Wiki for up-to-date information about CVS and its associtated tools.

If you do find anything useful on this page that is not yet in the Ximbiot - CVS Wiki and you have the time, please add it!

Wrappers (-t/-f)

Wrappers (-t/-f)

If you are looking to use -t/-f wrappers, you want the versions of CVS which contain this feature. Note that this is only somewhat related to -k wrappers, which are the wrappers that relate to binary files. The -k wrappers are found in all recent versions of CVS.

CVS's with -t/-f are available from CodeFab, Alexy Milov, and/or Apple.

Regarding specific issues, there have been a number of submitted patches (circa CVS 1.9). Many of them need miscellaneous cleanups, as described in HACKING. Almost all of them could use a sanity.sh testcase. There is a serious bug in -t/-f wrappers in CVS 1.9.26. Here is Wilfredo Sanchez's version of the client/server patch.

Jim Kingdon's own personal opinion is that I have serious doubts about whether the -t/-f wrapper feature should be in widely distributed versions of CVS in anything which strongly resembles its current form, given all the bugs and quirks. At a bare minimum, we would need test cases, to reduce the likelihood of more bugs where the feature clobbers people's sources. In general, there is a lot to be said for having special-purpose or experimental features, like -t/-f, handled via their own distributions, such as the CodeFab CVS, MacCVS 3.x, gcvs, Andreas Huber's OS/2 distribution, &c. Trying to conform to HACKING and all that stuff is a burden which doesn't necessarily make sense for all projects.

More specifically, here is a (partial) list of specific technical concerns. Again, this is just Jim Kingdon's opinion as of one point in time and there are ways to try to change my mind (see HACKING).

  • Testsuite.
  • Wrappers combine two features - filtering a file through a script and treating a directory as a single file. It is not at all clear to me that these belong as part of the same feature. And whether there is some fairly different way to solve the latter problem. For example, see this patch concerning problems calling dos2unix from wrappers. Another manifestation is that CVS, with -t/-f, assumes that the timestamp of a directory which is being wrapped means something about whether the contents of that directory are modified, and of course that is not a good assumption.
  • In general, wrappers calls are scattered throughout CVS without any particularly clear abstraction at work. It just isn't clean. I suspect this may be related to the previous item.
  • Client/server done in a clean way (no calls to an external "tar" program hardcoded into CVS, for example).
  • In terms of coding standards, checking for errors, freedom from bugs, and the like, most of the wrappers code I have seen could use some work. Today, src/wrapper.c is better than when it was first added to CVS, but I'd still point to HACKING and the FIXME comments and look for improvements.
  • The wrap_tocvs_process_file function needs to not use sprintf (see the FIXME there). This can cause core dumps if one specifies %s twice, but more seriously it is probably a security hole. Likewise wrap_fromcvs_process_file.

[Cyclic Home]

Derek Price, CVS developer and technical editor of Essential CVS (Essentials line from O'Reilly Press) , and others offer consulting services and training through Ximbiot.