bndtools / bnd

Bnd/Bndtools. Tooling to build OSGi bundles including Eclipse, Maven, and Gradle plugins.
https://bndtools.org
Other
528 stars 306 forks source link

Missing tasks in gradle #1807

Closed mnlipp closed 7 years ago

mnlipp commented 7 years ago

The documentation of the gradle plugin (https://github.com/bndtools/bnd/blob/master/biz.aQute.bnd.gradle/README.md#gradle-plugin-for-workspace-builds) states that the gradle plugin provides additional tasks.

However, trying to use the release task, I get an error from gradle that this task doesn't exists. A gradlew tasks --all lists (from all the additional tasks mentioned in the documentation) only the baseline task.

Actually, I don't really assume that nobody has noticed this before, so I'm probably doing something wrong. Considers this a documentation issue rather than an implementation issue. Nevertheless, regarding my attempt to release my bundle, I'm stuck.

bjhargrave commented 7 years ago

To use the Bnd Gradle plugin for workspace builds you

apply plugin: 'biz.aQute.bnd'

It sounds like you are using the Bnd Gradle plugin for non-workspace builds:

apply plugin: 'biz.aQute.bnd.builder'
mnlipp commented 7 years ago

Indeed, I am. Because I'm building a library and only want to make it "OSGi aware/useable". So there is no bnd-based way to release the bundle when using the non-workspace build?

bjhargrave commented 7 years ago

Releasing to a repository implies a workspace with configured repositories. When using a non-workspace build, you don't have any configured repositories to release a bundle into. Bnd just makes the bundle jar (and allows to you to baseline it). Releasing is done by other gradle plugins such as a publishing plugin.

mnlipp commented 7 years ago

Okay, understood. Thanks for the quick response.