Search code examples
ivyivyde

ivy and ivyde and FileSystem resolvers


I'm having an issue getting an ant/ivy build and eclipse/ivyde build to work well with each other.

Here's my setup, where 'git_root' is different for each developer:

/{git_root} |
             -/projectA
             -/B  |
                   - projectB1
                   - projectB2
             -ivy_build |
                        - ivy_settings.xml
                        - local_repository

my ivy_settings.xml contains a FileSystem resolver that must, of course, use absolute paths.

e.g.:

<filesystem name="local">
  <ivy pattern="${repository.dir}/[module]/ivy.xml" />
  <artifact pattern="${repository.dir}/[module]/[artifact].[ext]" />
</filesystem>

so now how do I define {repository.dir} in such a way to make both ant happy and ivyde/eclipse happy?


Solution

  • I normally use the ivy.settings.dir property which resolves to the directory local to the ivy settings file:

    <filesystem name="myrepos">
        <artifact pattern="${ivy.settings.dir}/local_repository/[organisation]/[artifact]-[revision].[ext]" />
    </filesystem>