I've searched a lot about this subject in the past. And we're currently using 
what Anders described. For completeness sake: you could possibly abuse 
classifiers for this as well.





Sander Verhagen
[  [email protected]  ]

NOTICE: my e-mail address has changed. You may still e-mail me at 
[email protected] but you will see me using [email protected] from 
now on. Feel free to update your address book.

-------- Original message --------
From: Anders Hammar <[email protected]>
Date:18/04/2015 12:35 (GMT-08:00)
To: Maven Users List <[email protected]>
Cc:
Subject: Re: what are some best practices for maven artifact naming when 
multiple code branches exist?

I would add a suffix to the version for each branch. For example, if trunk
is 1.0.0-SNAPSHOT, feature branch A would get version
1.0.0-featureA-SNAPSHOT.

/Anders

On Sat, Apr 18, 2015 at 9:10 PM, Nikita Tovstoles <
[email protected]> wrote:

> Suppose we have an app that's being developed on trunk and a couple of
> branches simultaneously - and we'd like to publish artifacts from each dev
> branch into our maven repo (so that we can run a cluster for each code
> branch). Currently the 'V' in GAV equals our CI's build plan execution
> number.
>
> What are some approaches for differentiating GAVs between each code branch?
> I can think of:
>
> 1) using different artifact names (ie myapp for trunk, myapp-b1 for branch1
> version, etc)
>
> 2) reset version numbers so that trunk's starts at 100, branch 1 starts at
> 10,000, etc (unlikely to collide in our case but seems cheesy)
>
> 3) Something else?
>
> thanks
>
> -nikita
>

Reply via email to