You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@subversion.apache.org by Michael Jervis <mi...@cse-servelec.com> on 2006/02/03 16:27:39 UTC
Automatic Property Setting
Hi,
I've been reading up on SVN in preparation to move to it from VSS.
Currently, in VSS we use the $Header$ and $Log$ keyword expansions in our
ASP files to identify the version of the file a lot to get an overview of
recent changes, and find out which version of the file is deployed to an
instance of the application.
I want to ensure that every ASP file (and a few other types) committed to
the repository has these keywords expanded. What is the best way to ensure
this? Automatic Property Setting appears to be a client side setting, if
another developer adds a file, is there a way to enforce the right property
setting for the ASP files?
Also SVN does not appear to have an equivalent of the $Log$ keyword, which
outputs the commit history as it's built up, e.g:
'$Log: /path/to/my.asp$
'48 5/01/04 10:50 mjervis
'Commit message 48
'
'47 27/10/03 14:00 another
'commit message 47
'
'46 22/10/03 14:03 adeveloper
'commit message 46
Is there something missing from the docs? Is there another way I can handle
this? We store important information in these messages that it would be very
handy to see in the file.
TIA,
Best regards
Michael Jervis,
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Automatic Property Setting
Posted by Ryan Schmidt <su...@ryandesign.com>.
On Feb 3, 2006, at 17:27, Michael Jervis wrote:
> Currently, in VSS we use the $Header$ and $Log$ keyword expansions
> in our
> ASP files to identify the version of the file a lot to get an
> overview of
> recent changes, and find out which version of the file is deployed
> to an
> instance of the application.
>
> I want to ensure that every ASP file (and a few other types)
> committed to
> the repository has these keywords expanded. What is the best way to
> ensure
> this? Automatic Property Setting appears to be a client side
> setting, if
> another developer adds a file, is there a way to enforce the right
> property
> setting for the ASP files?
You'll probably want to set up your clients with a config file which
turns on auto-props and specifies a set of keywords to automatically
apply to .asp files, and whatever other kind of automatic properties
you want to set.
To enforce this on the server site, you'll write a pre-commit hook
which checks all files in the incoming transaction for conformance
with your policy. Transactions that don't comply can then be
rejected, with an error message advising people where to download a
properly-configured config file.
> Also SVN does not appear to have an equivalent of the $Log$
> keyword, which
> outputs the commit history as it's built up, e.g:
>
> '$Log: /path/to/my.asp$
> '48 5/01/04 10:50 mjervis
> 'Commit message 48
> '
> '47 27/10/03 14:00 another
> 'commit message 47
> '
> '46 22/10/03 14:03 adeveloper
> 'commit message 46
>
> Is there something missing from the docs? Is there another way I
> can handle
> this? We store important information in these messages that it
> would be very
> handy to see in the file.
$Log$ is deliberately not available in Subversion.
http://subversion.tigris.org/faq.html#log-in-source
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Re: Automatic Property Setting
Posted by Mark Phippard <ma...@softlanding.com>.
"Michael Jervis" <mi...@cse-servelec.com> wrote on 02/03/2006
11:27:39 AM:
> I've been reading up on SVN in preparation to move to it from VSS.
>
> Currently, in VSS we use the $Header$ and $Log$ keyword expansions in
our
> ASP files to identify the version of the file a lot to get an overview
of
> recent changes, and find out which version of the file is deployed to an
> instance of the application.
>
> I want to ensure that every ASP file (and a few other types) committed
to
> the repository has these keywords expanded. What is the best way to
ensure
> this? Automatic Property Setting appears to be a client side setting, if
> another developer adds a file, is there a way to enforce the right
property
> setting for the ASP files?
>
> Also SVN does not appear to have an equivalent of the $Log$ keyword,
which
> outputs the commit history as it's built up, e.g:
Subversion does not support $Log$. See this FAQ:
http://subversion.tigris.org/faq.html#log-in-source
Auto-props are a client-side setting so you would want to be sure to get
the configuration in place on all developer's systems. They are your best
way to get these keywords added correctly.
To enforce the keywords, you would have to implement a pre-commit hook
that examined Added files to be sure they have the property set. If they
do not, you could reject the commit and give a message back to the user.
You cannot add the keywords as part of the hook.
Mark
_____________________________________________________________________________
Scanned for SoftLanding Systems, Inc. and SoftLanding Europe Plc by IBM Email Security Management Services powered by MessageLabs.
_____________________________________________________________________________
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org