If what you want is simply coherence in release version, use maven
multiproject.
You can have the 2 sub projects (api and core) inherit the version of
parent project :)
You can even have core depende on api with same version
I have the case here with a realm-impl and a realm-api, here is the api
dependency in impl:

        <dependency>
            <groupId>${pom.groupId}</groupId>
            <artifactId>Realms-api</artifactId>
            <version>${pom.currentVersion}</version>
            <type>jar</type>
        </dependency>


quite simple :)
as both api and impl inherit currentVersion from parent root project,
all goes well :)
I then simply go to root project and type
maven multiproject:install

it will build both jars in correct order :)
Dennis Kempin a écrit :

> Hello,
>
> I just discovered maven and I am really impressed by this project!
> To migrate my project to maven I am searching for a way to create two
> jar  files in one project.
>
> I would like to have a "./src/main/api" folder besides
> "./src/main/java"  and pack them into two different jars, to provide a
> single jar that only  contains the API that is needed to use my library.
>
> For now I use two seperated projects "core" and "core-api" while
> "core"  depends on "core-api". This also works great, but I think it
> would be more  elegant to have the API in the same project that will
> create a  "core-api-version.jar" besides the "core-version.jar".
>
> Do you think that it is possible? Or do you think I should stay at
> the  seperated projects due to some reasons (Maybe because
> implementation  versions can change while API versions stay at a
> specific version).
>
> Thanks and greetings
> Dennis Kempin
>
> PS: please pardon me. My english is bad.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to