Hi,

I'm looking for an easy solution to the following problem (if It's possible at 
all):

I have a project (say "MyJPAEntities") with several JPA entities which I commit 
to Nexus via Ivy. It gets versioned as - say - myjpaentities-1.0.jar.

Now a second project uses this jar which is retrieved with Ivy.

If I want to use the entities from the entity project within the second 
project, I need to reference the jar file name in persistence.xml:

  <jar-file>myjpaentities-1.0.jar</jar-file>

This works fine, except that I have to alter persistence.xml every time a new 
version of my entity project is committed to Nexus... (which is not safe/stable 
enough if someone else has to maintain the second project).


Two questions:

1) Is there an easy way to change the naming scheme for one specific jar *on 
retrieve*? That is, I'd like to retrieve all jars with their version number, 
except my entity project, which I'd like to retrieve with the base name without 
version number ("myjpaentities.jar").

2) Or, if that's not possible, is it possible to retrieve just the *name* of an 
artifact (and not the jar itself)? This way, I could filter/change 
persistence.xml automatically in my Ant script.


Sorry if this is an old topic, but I could find neither a similar question nor 
any solution.

Thanks,
Thomas

Reply via email to