how to view the dependency tree using buildr

72 views Asked by At

Is there a way to view the dependency tree using buildr?

Something similar to what maven provides using the command: "mvn dependency:tree".

1

There are 1 answers

0
Peter Donald On

There is no task built in but depending on what you specifically need to do it is relatively easy to whip up some code to do it. We often write a little bit of code that looks like the following to list all transitive dependencies of a specific dependency.

task 'showdeps' do
  raise 'Need to define ENV property DEP' unless ENV['DEP']
  Buildr.transitive(ENV['DEP']).each do |a|
    puts a.to_spec
  end
end

And then run this via

buildr showdeps DEP=edu.ucar:tds:jar:classes:4.3.20

Not eactly what you asked for but hope this helps.