Inject Update Site URL into top-level feature [message #504665] |
Mon, 21 December 2009 18:34  |
Eclipse User |
|
|
|
Hi all,
Our product consists of a top-level feature which "contains"
sub-features which each contain a few plugins (a pretty standard
organization based on what Eclipse itself does). Like so:
com.ourcompany.common.feature
|--com.ourcompany.one.feature
| |--com.ourcompany.one.plugin
|--com.ourcompany.another.feature
|--com.ourcompany.another.plugin
So we have an update site with a single category containing only the one
toplevel feature (com.ourcompany.common.feature). This works just fine,
but the only problem is that even when all these features are installed,
users must enter the URL into their update manager manually, rather than
it already being in the list (as Core Eclipse update sites are).
In 3.3, I believe we had this functionality working, by making a
modification like the following in the toplevel feature.xml
===============
<?xml version="1.0" encoding="UTF-8"?>
<feature
id="com.ourcompany.common.feature"
label="%featureName"
version="1.0.0.qualifier"
provider-name="%providerName">
<description url="%featureDescritpionUrl">
%featureDescription
</description>
<copyright url="%featureCopyrightUrl">
%featureCopyright
</copyright>
<license url="%featureLicenseUrl">
%featureLicense
</license>
<url>
<update label="Our Product Name's Update Site"
url="http://the.url.com:8080/update"/>
<discovery label="Our Product Name"
url="http://the.url.com:8080/update"/>
</url>
...information omitted to protect the innocent, etc...
</feature>
============
So has this changed with p2? I've had a little trouble finding anything
documented on this. According to the doc I've read, the same process
should still apply, but it doesn't work (or produce error messages) in
our 3.5 environment. Anyone have any ideas?
Thanks,
Troy Nichols
|
|
|
Re: Inject Update Site URL into top-level feature [message #504711 is a reply to message #504665] |
Tue, 22 December 2009 05:00  |
Eclipse User |
|
|
|
As far as I understand, this can be achieved via a p2.inf file in your
com.ourcompany.common.feature that contains something like this:
instructions.configure=\
org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type :0,location:http${#58}//www.knime.org/update/2.1);\
org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type :1,location:http${#58}//www.knime.org/update/2.1);
This, however, does not work in 3.4 so we did it the hard way and
modified two files in the configuration/.settings directory of the final
product:
configuration/.settings/org.eclipse.equinox.p2.artifact.repo sitory.prefs:
repositories/http\:__www.knime.org_update_2.1/url=http\://www.knime.org/update/2.1
repositories/http\:__www.knime.org_update_2.1/enabled=true
configuration/.settings/org.eclipse.equinox.p2.metadata.repo sitory.prefs:
repositories/http\:__www.knime.org_update_2.1/url=http\://www.knime.org/update/2.1
repositories/http\:__www.knime.org_update_2.1/enabled=true
Hope this helps,
Thorsten
|
|
|
Re: Inject Update Site URL into top-level feature [message #603842 is a reply to message #504665] |
Tue, 22 December 2009 05:00  |
Eclipse User |
|
|
|
As far as I understand, this can be achieved via a p2.inf file in your
com.ourcompany.common.feature that contains something like this:
instructions.configure=\
org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type :0,location:http${#58}//www.knime.org/update/2.1);\
org.eclipse.equinox.p2.touchpoint.eclipse.addRepository(type :1,location:http${#58}//www.knime.org/update/2.1);
This, however, does not work in 3.4 so we did it the hard way and
modified two files in the configuration/.settings directory of the final
product:
configuration/.settings/org.eclipse.equinox.p2.artifact.repo sitory.prefs:
repositories/http\:__www.knime.org_update_2.1/url=http\://www.knime.org/update/2.1
repositories/http\:__www.knime.org_update_2.1/enabled=true
configuration/.settings/org.eclipse.equinox.p2.metadata.repo sitory.prefs:
repositories/http\:__www.knime.org_update_2.1/url=http\://www.knime.org/update/2.1
repositories/http\:__www.knime.org_update_2.1/enabled=true
Hope this helps,
Thorsten
|
|
|
Powered by
FUDForum. Page generated in 0.04413 seconds