Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tycho-user] way to check required-plugin version


Hi,

On Fri, Aug 4, 2017 at 10:44 AM, LE FEVRE FRANCOIS <francois.le-fevre@xxxxxx> wrote:

For the bundles that are extracted from the children module, sometimes the developer upgrade the version of the module but forgot to upgrade the different modules that list this plugin as required bundle.
[...]
The developer upgrade the version of A1 to 1.1.0 and reflect it in A2 but forgot to do it in A3


First, this is actually a good OSGi practice to *not* update versions unless needed (ie if resulting binary did chnage). Not changing version allows to have a broad compatibility range, which can be pretty convenient. PDE API Tools can help (in the IDE) to remind to update versions according to OSGi best practices, at Tycho level, there isn't an easy way to enable PDE API Tools.
However, if you're concerned about compatibility, you can use a combination of reproducible version quilifiers ( https://wiki.eclipse.org/Tycho/Reproducible_Version_Qualifiers#What_does_this_actually_do.3F ) and of https://www.eclipse.org/tycho/sitedocs-extras/tycho-p2-extras-plugin/compare-version-with-baselines-mojo.html . That would mostly make your build fail is the content of the resulting jar actually changed (ie if there were code change mostly). Then, from this failure, the developer gets reminded to update the version.
 

How can we check automatically that all versions are the same for a given module?
[...]

How can we gather the fact that in all plugins in the project A, the A1 version to be used is 1.1.0


There might be existing mojos or you can write your own one that looks at all modules in the reactor and fail if they are not equals.
But as far as I know, it's not a common practice.
 

Is there a way to define outside the version of the required bundles that belongs to the same project?


No.
 
--
Mickael Istria
Eclipse IDE developer, at Red Hat Developers community

Back to the top