I'm working with ivy 2.1.0 and seem to be having some issues getting at some of
the metadata that is supposed to be available.
Currently I'm trying to get a list of all modules in the repository regardless
of what branch they are in (and I want to know what branch they are in). I
have tried this with two methods, both of which seem to bring me to a dead-end
(through the ivy ant-tasks and through direct access to the ivy API).
Here is the ant task call that I use:
<ivy:listmodules organisation="MyOrg" module="*" revision="*" branch="*"
property="ivy.modules.[module].[branch].[revision]" value="found"/>
When I try to print out all of the ivy.modules.* properties I get one for each
module, but it ignores the branches.
When I try a similar call through the API:
ModuleRevisionId[] ids = ivy.listModules(ModuleRevisionId
.newInstance("MyOrg", "*",
PatternMatcher.ANY_EXPRESSION, "*"), ivy.getSettings()
.getMatcher(PatternMatcher.EXACT_OR_REGEXP));
I get back a list of module ids. Some of which are duplicated (I'm assuming
these are ones from the branches as well as non-branches). However, when I
loop through them and use getBranch() on each of the ids it returns null.
Also, if I use ivy.findModule(id) and look for the branch in there, it also has
null for the branch.
Any ideas on how to do this? Is there a way I can query the repo for a list of
branches? I know our settings work with branching because all of our projects
that use the branches work correctly. It is only when we try and get some
report information from the ivy repository that we seem to be having trouble.
Thanks.
James Davis * QA Engineer II/Software Engineer
Applied Technical Systems, Inc. * Information Engineering
web: www.atsid.com * e-mail: [email protected]
(p) 360.698.7100 x241 * (f) 360.698.7200