[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Replace keywords instead of expanding them

From: David Weintraub <qazwart_at_gmail.com>
Date: 2005-05-25 23:10:29 CEST

SCCS uses this method to expand keywords. In order to implement it,
SCCS would expand their keyword when a file was checkedout "read
only", but would not expand the keyword when the file was checked out
read/write for editing.

The results were a mess. Users would check out a file read only --
thus the keyword was expanded, edit the file, then realize they
couldn't check the file back in. They would then checkout another
version as read/write, copy their edited version with the expanded and
now lost keywords over the newly checked out version, then checked the
file back in. I would spend a lot of time replacing the expanded
keywords with their original counterparts. A big fat maintenance
headache. It was one of the reasons I was happy to switch to RCS when
it came out.

Besides, Subversion doesn't require file locking, so how would
Subversion know when to expand the keywords and when to leave the
keywords alone?

This type of feature is easily implemented in a build system. Create a
macro that the makefile expands before it does its compiling. In fact,
this feature is built right into Ant.

On 5/24/05, Christoph Hirzel <hirzel@indel.ch> wrote:
> Hi
>
> Does anybody know if it is possible to tell subversion to replace a
> keyword (e.g. $Revision$) instead of expanding it. Currently the
> following statement
>
> $Revision$
>
> is expanded to e.g.
>
> $Revision: 144 $
>
> What I would need is a replacement to just
>
> 144
>
> Can anybody help me.
>
> Thank you
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
> For additional commands, e-mail: users-help@subversion.tigris.org
>
>

-- 
--
David Weintraub
qazwart@gmail.com
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed May 25 23:12:27 2005

This is an archived mail posted to the Subversion Users mailing list.