You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by Oleg Taranenko <ta...@googlemail.com> on 2009/02/22 08:04:12 UTC

Auto creating the tool version string

Hello Users,

  I want to get the version in form toolname-1.0.1-build_476-20090217
  where 1.0.1 is maven's versionId attribute, 476 - subversion's build
  number, and 20090217 - date of release.

  Could someone pointing how? I hope I'm not a first wishing this.

  Thanks in advance, Oleg

-- 
Best regards,
 Oleg                          mailto:taranenko.forums@gmail.com


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Auto creating the tool version string

Posted by Oleg Taranenko <ol...@googlemail.com>.
Wendy,

thank you. Exactly what I need.



am Sunday, February 22, 2009 um 4:04 PM schrieben Sie:

> On Sun, Feb 22, 2009 at 7:00 AM, Google Mail
> <ol...@googlemail.com> wrote:

>> Is there maven support to supply this three parameters (versionId, svn
>> version and compile timestamp) direct into the java source code
>> without handy synchronization with pom.xml, svn info and so on?

> Take a look at the buildnumber plugin [1] for the svn revision and
> date.  It will set properties, which you can then use in the pom or
> filter into other files.

> [1] http://mojo.codehaus.org/buildnumber-maven-plugin/usage.html




-- 
Mit freundlichen Grüßen
Oleg Taranenko
mailto:olegtaranenko@googlemail.com



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Auto creating the tool version string

Posted by Wendy Smoak <ws...@gmail.com>.
On Sun, Feb 22, 2009 at 7:00 AM, Google Mail
<ol...@googlemail.com> wrote:

> Is there maven support to supply this three parameters (versionId, svn
> version and compile timestamp) direct into the java source code
> without handy synchronization with pom.xml, svn info and so on?

Take a look at the buildnumber plugin [1] for the svn revision and
date.  It will set properties, which you can then use in the pom or
filter into other files.

[1] http://mojo.codehaus.org/buildnumber-maven-plugin/usage.html

-- 
Wendy

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Auto creating the tool version string

Posted by Stephen Connolly <st...@gmail.com>.
There are ways... they probably involve creating manifest entries

2009/2/22 Google Mail <ol...@googlemail.com>

> Stephen,
>
> another chanllenge,
>
> mytool --version should give
>
> mytool, version 1.0-SNAPSHOT (b476)
>   compiled Feb 17 2009, 12:42:22
>
> Is there maven support to supply this three parameters (versionId, svn
> version and compile timestamp) direct into the java source code
> without handy synchronization with pom.xml, svn info and so on? May be
> with help of release plugin?
>
> Thought?
>
> am Sunday, February 22, 2009 um 12:51 PM schrieben Sie:
>
> > I understand what you are trying to do, but you will end up losing the
> > version range functionality in maven with version numbers in that format
>
> > have a look at maven's rules fir comparing version numbers, then look
> > at my bitchfest with Jason over me wanting five digit support and
> > Jason saying m3 will be osgi format version numbers on this list some
> > time in the past two weeks
>
> > if you can stick with maven conventions, your life will be much
> > easier... drink the damn kool aid
>
> > Sent from my [rhymes with myPod] ;-)
>
> > On 22 Feb 2009, at 07:04, Oleg Taranenko <
> taranenko.forums@googlemail.com
>  >> wrote:
>
> >> Hello Users,
> >>
> >>  I want to get the version in form toolname-1.0.1-build_476-20090217
> >>  where 1.0.1 is maven's versionId attribute, 476 - subversion's build
> >>  number, and 20090217 - date of release.
> >>
> >>  Could someone pointing how? I hope I'm not a first wishing this.
> >>
> >>  Thanks in advance, Oleg
> >>
> >> --
> >> Best regards,
> >> Oleg                          mailto:taranenko.forums@gmail.com
> >>
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> >> For additional commands, e-mail: users-help@maven.apache.org
> >>
>
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> > For additional commands, e-mail: users-help@maven.apache.org
>
>
>
>
> --
> Mit freundlichen Grüßen
> Google Mail
> mailto:olegtaranenko@googlemail.com
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: Auto creating the tool version string

Posted by Google Mail <ol...@googlemail.com>.
Stephen,

another chanllenge,

mytool --version should give

mytool, version 1.0-SNAPSHOT (b476)
   compiled Feb 17 2009, 12:42:22

Is there maven support to supply this three parameters (versionId, svn
version and compile timestamp) direct into the java source code
without handy synchronization with pom.xml, svn info and so on? May be
with help of release plugin?

Thought?

am Sunday, February 22, 2009 um 12:51 PM schrieben Sie:

> I understand what you are trying to do, but you will end up losing the
> version range functionality in maven with version numbers in that format

> have a look at maven's rules fir comparing version numbers, then look
> at my bitchfest with Jason over me wanting five digit support and  
> Jason saying m3 will be osgi format version numbers on this list some
> time in the past two weeks

> if you can stick with maven conventions, your life will be much  
> easier... drink the damn kool aid

> Sent from my [rhymes with myPod] ;-)

> On 22 Feb 2009, at 07:04, Oleg Taranenko <taranenko.forums@googlemail.com
 >> wrote:

>> Hello Users,
>>
>>  I want to get the version in form toolname-1.0.1-build_476-20090217
>>  where 1.0.1 is maven's versionId attribute, 476 - subversion's build
>>  number, and 20090217 - date of release.
>>
>>  Could someone pointing how? I hope I'm not a first wishing this.
>>
>>  Thanks in advance, Oleg
>>
>> -- 
>> Best regards,
>> Oleg                          mailto:taranenko.forums@gmail.com
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
>> For additional commands, e-mail: users-help@maven.apache.org
>>

> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org




-- 
Mit freundlichen Grüßen
Google Mail
mailto:olegtaranenko@googlemail.com



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: Auto creating the tool version string

Posted by Stephen Connolly <st...@gmail.com>.
I understand what you are trying to do, but you will end up losing the  
version range functionality in maven with version numbers in that format

have a look at maven's rules fir comparing version numbers, then look  
at my bitchfest with Jason over me wanting five digit support and  
Jason saying m3 will be osgi format version numbers on this list some  
time in the past two weeks

if you can stick with maven conventions, your life will be much  
easier... drink the damn kool aid

Sent from my [rhymes with myPod] ;-)

On 22 Feb 2009, at 07:04, Oleg Taranenko <taranenko.forums@googlemail.com 
 > wrote:

> Hello Users,
>
>  I want to get the version in form toolname-1.0.1-build_476-20090217
>  where 1.0.1 is maven's versionId attribute, 476 - subversion's build
>  number, and 20090217 - date of release.
>
>  Could someone pointing how? I hope I'm not a first wishing this.
>
>  Thanks in advance, Oleg
>
> -- 
> Best regards,
> Oleg                          mailto:taranenko.forums@gmail.com
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org