You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@felix.apache.org by Patrick Shea <pa...@ps1.net> on 2008/04/25 19:53:42 UTC
OBR deploy-file
I'm trying to use the obr:deploy-file goal but the plugin never upload my jar to the remote repository, it just updates the repository.xml
Here's my config:
<plugin>
<groupId>org.apache.felix</groupId>
<artifactId>maven-obr-plugin</artifactId>
<executions>
<execution>
<id>install</id>
<phase>install</phase>
<goals>
<goal>install-file</goal>
</goals>
</execution>
<execution>
<id>deploy</id>
<phase>deploy</phase>
<goals>
<goal>deploy-file</goal>
</goals>
</execution>
</executions>
<configuration>
<groupId>${pom.groupId}</groupId>
<artifactId>${pom.artifactId}</artifactId>
<version>${pom.version}</version>
<packaging>bundle</packaging>
<repositoryId>${project.distributionManagementArtifactRepository.id}</repositoryId>
<url>${project.distributionManagementArtifactRepository.url}</url>
<file>${pom.artifactId}-${pom.version}.jar</file>
</configuration>
</plugin>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org
Re: OBR undeploy-file
Posted by Stuart McCulloch <st...@jayway.net>.
2008/4/29 <an...@orange-ftgroup.com>:
> Hi everybody,
>
> I've seen there is a "clean" goal on the local repository, which
> suppresses the references to non-existent files. Is there something
> similar for a remote repository ?
not at the moment, but I guess it would be possible by checking
for non-working or invalid bundle URLs in the remote repository
feel free to open a JIRA request for this feature - if you have
a suggested patch for this then that would be even better :)
Slightly different, is there a way to "undeploy" a bundle from a remote
> OBR (i.e. to remove the reference to a bundle from a remote
> repository.xml, without editing the file manually) ?
>
no, you have to modify the file manually at the moment, but this
could be added as a new goal (create a separate JIRA issue)
> Thanks,
>
> Anne
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>
--
Cheers, Stuart
OBR undeploy-file
Posted by an...@orange-ftgroup.com.
Hi everybody,
I've seen there is a "clean" goal on the local repository, which
suppresses the references to non-existent files. Is there something
similar for a remote repository ?
Slightly different, is there a way to "undeploy" a bundle from a remote
OBR (i.e. to remove the reference to a bundle from a remote
repository.xml, without editing the file manually) ?
Thanks,
Anne
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
For additional commands, e-mail: users-help@felix.apache.org
Re: OBR deploy-file
Posted by Stuart McCulloch <st...@jayway.net>.
2008/4/26 Patrick Shea <pa...@ps1.net>:
> I'm trying to use the obr:deploy-file goal but the plugin never upload my
> jar to the remote repository, it just updates the repository.xml
>
that's correct, it only updates the repository.xml - if you want to upload
the jar then
you need to use the standard deploy:deploy-file goal, which you can combine
on
the same command-line / build phase:
mvn deploy:deploy-file bundle:deploy-file ...etc...
(otherwise we'd end up duplicating the whole deploy-file code in the
bundleplugin)
Note *-file goals are mainly meant for command-line use when you have
bundles
that are not managed by Maven, or you want full control over the bundle URL
that
goes in the repository.xml
if you use <packaging>bundle</packaging> then you will automatically get the
remote repository.xml updated when you use "mvn deploy" as long as you set
the remoteOBR setting, because the "bundle:deploy" goal is part of the
bundle
lifecycle...
from components.xml in the bundleplugin:
<!-- START SNIPPET: bundle-lifecycle -->
<phases>
<process-resources>org.apache.maven.plugins:maven-resources-plugin:resources</process-resources>
<compile>org.apache.maven.plugins:maven-compiler-plugin:compile</compile>
<process-test-resources>org.apache.maven.plugins:maven-resources-plugin:testResources</process-test-resources>
<test-compile>org.apache.maven.plugins:maven-compiler-plugin:testCompile</test-compile>
<test>org.apache.maven.plugins:maven-surefire-plugin:test</test>
<package>org.apache.felix:maven-bundle-plugin:bundle</package>
<install>
org.apache.maven.plugins:maven-install-plugin:install,
org.apache.felix:maven-bundle-plugin:install
</install>
<deploy>
org.apache.maven.plugins:maven-deploy-plugin:deploy,
org.apache.felix:maven-bundle-plugin:deploy
</deploy>
</phases>
<!-- END SNIPPET: bundle-lifecycle -->
also, if your repository.xml is located alongside your remote Maven
repository
but you don't use <packaging>bundle</packaging> then you can still use the
simpler "bundle:deploy" goal like so:
mvn deploy bundle:deploy -DremoteOBR ....etc....
(you need to at least run install/deploy before bundle:deploy so Maven will
attach the project artifact - otherwise we won't have its metadata
available)
Here's my config:
>
> <plugin>
> <groupId>org.apache.felix</groupId>
> <artifactId>maven-obr-plugin</artifactId>
> <executions>
> <execution>
> <id>install</id>
> <phase>install</phase>
> <goals>
> <goal>install-file</goal>
> </goals>
> </execution>
> <execution>
> <id>deploy</id>
> <phase>deploy</phase>
> <goals>
> <goal>deploy-file</goal>
> </goals>
> </execution>
> </executions>
> <configuration>
> <groupId>${pom.groupId}</groupId>
> <artifactId>${pom.artifactId}</artifactId>
> <version>${pom.version}</version>
> <packaging>bundle</packaging>
> <repositoryId>${project.distributionManagementArtifactRepository.id
> }</repositoryId>
>
> <url>${project.distributionManagementArtifactRepository.url}</url>
> <file>${pom.artifactId}-${pom.version}.jar</file>
> </configuration>
> </plugin>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@felix.apache.org
> For additional commands, e-mail: users-help@felix.apache.org
>
>
--
Cheers, Stuart