Mark Reibert wrote:
> On Thu, 2008-06-05 at 08:34 -0400, Andy Levy wrote:
>> On Thu, Jun 5, 2008 at 8:11 AM, massimiliano
>> <massimiliano.cialdi_at_powersoft.it> wrote:
>>> how can "read" the base_dir revision and put in a C string automagically (or
>>> through a script)?
>> http://subversion.tigris.org/faq.html#version-value-in-source
>
> The problem - or at least inconvenience - with svnversion is it requires
> a working copy. A build purist prefers to "svn export" a tag and build
> from the export. This way the build is of exactly the same source
> delivered to the customers/users.
>
> One option is to do something like "svn info <repo_url>/tags/<release>"
> and grab the commit or "last changed" revision. Then export, munge the
> release and commit revision into the source where needed, and build.
>
Hi Marc,
on your svn-server you can use "svnlook youngest" to retrieve the
revision number. On a different machine you can use a regex to retrieve
the revision number as last line from your "svn export" output.
I think it is always a bad idea to couple your source code to a SCM(even
as good as SVN) via using such keywords. You will agree if you try to
migrate your source from one SCM to another.
Greetings,
Lutz
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: users-help_at_subversion.tigris.org
Received on 2008-06-09 00:10:50 CEST