svnsvn-propset

auto add comments in the header


With SVN, is it possible to incude automaticlly a "comment" tempate when I add a new file ?

For example, I want to add automatically this comment when I add a file "*.pl" :

# SVN information :
#  @Autor : $Author$
#  @Autor : $Revision$
#  @Id : $Id$
#  @Date : $Date$

Thanks for your help.


Solution

  • Subversion does not have this functionality. You can create a pre-commit hook script to check for the existence of this block and reject a commit which contains a .pl file but lacks the block, but with SVN alone you cannot automatically add content as you describe.