Great, I will investigate in that direction(s).

I also thought about another solution which might be simpler. In the assembly 
we have a kind of main feature which does have a version. Is there a way to 
retrieve it programmatically?

Regards,
JP

[@@ OPEN @@]

-----Message d'origine-----
De : Jean-Baptiste Onofré [mailto:[email protected]] 
Envoyé : lundi 5 octobre 2015 17:15
À : [email protected]
Objet : Re: Karaf assembly version

You can do that with resources-plugin and Maven directly (and also the artifact 
build helper).

Regards
JB

On 10/05/2015 05:11 PM, CLEMENT Jean-Philippe wrote:
> ...and during the assembly, is there a way to write it to a file?
>
> JP
>
> [@@ OPEN @@]
>
>
> -----Message d'origine-----
> De : Jean-Baptiste Onofré [mailto:[email protected]] Envoyé : lundi 5 
> octobre 2015 16:52 À : [email protected] Objet : Re: Karaf 
> assembly version
>
> So basically the project.version.
>
> I don't see anything already there for that. Sorry.
>
> Regards
> JB
>
> On 10/05/2015 04:48 PM, CLEMENT Jean-Philippe wrote:
>> Hi JB,
>>
>> The info shows the Karaf version (for instance 3.0.2), but I would like the 
>> assembly one, i.e. the one used to name the assembly archives (both .tar.gz 
>> and .zip).
>>
>> I would need this information at runtime. Is there a way to retrieve it?
>>
>> JP
>>
>> [@@ OPEN @@]
>>
>>
>> -----Message d'origine-----
>> De : Jean-Baptiste Onofré [mailto:[email protected]] Envoyé : lundi 5 
>> octobre 2015 16:06 À : [email protected] Objet : Re: Karaf 
>> assembly version
>>
>> Hi JP,
>>
>> you mean the version that you have in shell:info for instance ?
>>
>> You have a System property at runtime about that. I guess you need at build 
>> time ?
>>
>> Regards
>> JB
>>
>> On 10/05/2015 03:46 PM, CLEMENT Jean-Philippe wrote:
>>> Dear Karaf,
>>>
>>> I would like to retrieve the version used by the karaf-maven-plugin during 
>>> the assembly (for instance sample-assembly-1.0.0-SNAPSHOT.tar.gz => 
>>> 1.0.0-SNAPSHOT). The goal is to show it inside the application (something 
>>> like the "about" box).
>>>
>>> Is there a simple way to do so?
>>>
>>> Kind regards,
>>> JP
>>>
>>> [@@ OPEN @@]
>>>
>>
>> --
>> Jean-Baptiste Onofré
>> [email protected]
>> http://blog.nanthrax.net
>> Talend - http://www.talend.com
>>
>
> --
> Jean-Baptiste Onofré
> [email protected]
> http://blog.nanthrax.net
> Talend - http://www.talend.com
>

--
Jean-Baptiste Onofré
[email protected]
http://blog.nanthrax.net
Talend - http://www.talend.com

Reply via email to