Subversion server

Table of Contents

Configuration
Create/restore a repository
Add $Id$ tag to your project files

Add $Id$ tag to your project files

by ross at 10:51:54 on April 21, 2012

Setup subversion client

This is setup for PHP projects.
Replace *.php with your language file extension.

Edit ~/.subversion/config:

[miscellany]
enable-auto-props = yes

[auto-props]
*.php = svn:keywords=Id
*.js = svn:keywords=Id

The Id tag

Add to your new files string $Id$ — svn will expand it with the ID on commit.

To add the tag to existing files:

$ cd /to/your/checked-out/project
$ find . \( -name "*.php" -o -name "*.js" \) -exec svn propset svn:keywords Id {} \;
$ svn commit -m "svn propset for Id"

 

Comments