Once in a while the tycho team post a request to test new versions of Tycho.
If the Tycho version is already released you can try it out by running mvn with appropriate tychoVersion
flag set, i.e.:
$ mvn -DtychoVersion=1.0.0 clean install
Will run with Tycho version 1.0.0.
If the Tycho version is not yet released, but only staged you need to let maven know about the plugin repository.
You can do that by manually adding that to a projects pom.xml
file but that very easily becomes tedious.
An easier approach is to add it to ~/.m2/settings.xml
as a profile you can turn on and off.
To do this add the following to your ~/.m2/settings.xml
in a <profiles>
setting:
<profile>
<id>tycho-staging</id>
<properties>
<tycho.staging.repo>https://oss.sonatype.org/content/repositories/orgeclipsetycho-999</tycho.staging.repo>
</properties>
<pluginRepositories>
<pluginRepository>
<id>tycho-staged</id>
<name>Staging repository for Tycho builds</name>
<url>${tycho.staging.repo}</url>
</pluginRepository>
</pluginRepositories>
</profile>
This defines a profile that adds the ${tycho.staging.repo}
to the list of plugin repositories.
Warning
|
Don’t put this profile in activeProfiles. Only enable it when using for tycho staging testing. |
Now you can without changing any of your pom’s just run:
$ mvn -P tycho-staging -DtychoVersion=1.0.0 clean install
And next time you want to test a new staging version of tycho you just go to your ~/.m2/settings.xml and update the url.
Because of the defined property you can also be even more explicit and do:
$ mvn -P tycho-staging -DtychoVersion=1.0.0 -Dtycho.staging.repo=https://oss.sonatype.org/content/repositories/orgeclipsetycho-999 clean install
With this in place you only have to run that line assuming you have the version and staging.repo url available.
No additional tweaking in pom.xml or settings.xml needed.