Marcus Lindblom wrote:
> Hi Dirk,
>
> Dirk Reiners wrote:
>  >
>   
>> I'm interested. I looked at subwcrev, but it didn't look that obvious.
>> Especially since it's a Windows executable that's part of
>> TortoiseSVN... ;) I would assume that svn can do keyword substitution,
>> so I'm not sure what I need it for.
>>     
> I forgot about it being windowsy. Sorry. :) Anyway, it's a simple 
> macro-processor that substitutes keywords from a file, writing another, 
> based on the local working copy status (revisions, url, modification, 
> last commit date, etc.).
>
> I suppose you could use svn to do keyword substitution instead. One nice 
> thing with it is that it actually checks your local copy, so you can use 
> it to attach some thing like 'modified' automatically if you are making 
> a build with local (non-commited) modifications. That should also be 
> possible with barebone-svn I suppose.
>
> But perhaps this svn-stuff is not so much an issue for OpenSG as it 
> might be for others (such as myself), since the build-system puts 
> together dailybuilds all the time, so it's sufficiently automated anyway.
>
> Anyway, I'll post the example tomorrow when I'm in the office again. :)
>   
Sorry for being late with this. :-/

I have a template file which declares the following function:

std::string Build::getRevision()
{
    const char *commit = "(commited $WCDATE$)";
    std::ostringstream os;
    os << "Rev: $WCRANGE$ ";
    os << $WCMODS?"(modified)":commit$;
    os << " Repo: $WCURL$";
    return os.str();
}

which is resolved, when run via subwcrev, to something like:

std::string Build::getRevision()
{
    const char *commit = "(commited 2006/09/11 14:41:02)";
    std::ostringstream os;
    os << "Rev: 1751 ";
    os << "(modified)";
    os << " Repo: svn://loke.mentice.com/styx/trunk/Core";
    return os.str();
}

/Marcus

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Opensg-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensg-users

Reply via email to