
One of the things I've really liked, and have used for years, is the keyword expansion feature of CVS. This means that, for example, my Perl code can maintain version strings by simply setting
my $VERSION = "$Id$";
at the top of a file - and CVS automatically expands it into something useful. I want the same functionality from Subversion / SVN. Fortunately, svn's developers thought of this, and kindly provided a method of enabling keyword expansion on a per-file basis (so where you have to specifically turn keyword expansion off in cvs with -kb, in svn you have to turn it on, and on a per file basis.)
To enable keyword expansion for $Id$ for a file mycode.pl, you'll want to execute the following:
svn propset svn:keywords "Id" mycode.pl
posted at: 09:13 | path: /technical | permanent link to this entry
