You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@buildr.apache.org by Esko Luontola <es...@orfjackal.net> on 2009/10/12 22:09:07 UTC

Uploading only artifacts which have changed since the previous release

I'm currently using Maven, but considering switching to Buildr. The 
project where I would use Buildr is a multi-module project written in 
Java and Scala. Git is used for version control.

But first I would need to know, that how I can handle the following use 
case in Buildr:

The project has two artifacts/modules: app-api and app-core. Both of 
them are stored in the same Git repository.
- When there is a new release of app-core, but there are no changes to 
app-api, then only the version number of app-core should be increased 
and only app-core should be uploaded to the Maven repository. The 
app-core will refer to the old version of app-api.
- When there are changes in both app-api and app-core, then the version 
number of both of them should be increased, and both of them should be 
uploaded to the repository.

This would make it possible to release minor features and bugfixes of 
the system, without the users of the system needing to update their 
dependencies, because the users depend only on the API artifact.

(In reality the project is an application server which has at least a 
public API for application programmers, and an internal API for plugin 
writers. Also the implementation of the application server is divided 
into multiple modules, although with the implementation modules it 
doesn't matter even if their version numbers are increased 
unnecessarily. More details at 
http://blog.orfjackal.net/2009/05/version-number-management-for-multi.html)

The question is:

- How can I implement this kind of a selective artifact uploading in Buildr?
- Would it be possible to parameterize or modify the upload task, so 
that it uploads only artifacts within a specific version number or 
version number range?
- Can I hook some code into the upload task, which would check whether 
the code of a module has changed since the previous release, and would 
cancel the upload task if the module's version number has not been 
increased?

-- 
Esko Luontola
www.orfjackal.net