ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Matt Benson <gudnabr...@gmail.com>
Subject Re: Ant Version
Date Mon, 09 Dec 2013 20:56:59 GMT
Looks like Main.getAntVersion() is your friend.

Matt


On Mon, Dec 9, 2013 at 2:50 PM, Andre-John Mas <andrejohn.mas@gmail.com>wrote:

> Hi,
>
> This was the Get Task, whereby I was getting the ant version for use in
> the user-agent response. I am using the value uninterpreted.
>
> André-John
>
> Sent from my phone. Envoyé depuis mon téléphone.
>
> > On Dec 9, 2013, at 14:23, Matt Benson <gudnabrsam@gmail.com> wrote:
> >
> > Are you looking for compatibility with the version?  I.e., this task will
> > work on versions >= n?  A commonly taken approach there is to use the
> > presence of some particular class introduced in the target version,
> rather
> > than fiddling with version numbers per se.
> >
> > HTH,
> > Matt
> >
> >
> > On Mon, Dec 9, 2013 at 1:08 PM, Andre-John Mas <andrejohn.mas@gmail.com
> >wrote:
> >
> >> Hi,
> >>
> >> I recently made a code contribution and had the task get the version
> from
> >> the Main class. I appreciate this probably want the best approach and I
> am
> >> trying to consider options going forward. I had looked at the
> ant.version
> >> property, but the is only available in the project scope and also
> limited
> >> to the 'long' version.
> >>
> >> Some possibilities I am thinking of going forward:
> >> - Version class
> >> - AntRuntime class
> >>
> >> Does anyone else have suggestions or preferences as to the best way
> going
> >> forward?
> >>
> >> André-John
> >>
> >> Sent from my phone. Envoyé depuis mon téléphone.
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> >> For additional commands, e-mail: dev-help@ant.apache.org
> >>
> >>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@ant.apache.org
> For additional commands, e-mail: dev-help@ant.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message