generated .graphml files name contain the configuration name

This commit is contained in:
Johannes Rudolph 2012-05-23 12:28:18 +02:00
parent b30519f2d4
commit 18d2663a88
1 changed files with 3 additions and 3 deletions

View File

@ -42,7 +42,7 @@ object Plugin extends sbt.Plugin {
ivyReport <<= ivyReportFunction map (_(config.toString)) dependsOn(update),
asciiGraph <<= asciiGraphTask,
dependencyGraph <<= printAsciiGraphTask,
dependencyGraphML <<= dependencyGraphMLTask
dependencyGraphML <<= dependencyGraphMLTask(config)
))
def asciiGraphTask = (ivyReport) map { report =>
@ -52,9 +52,9 @@ object Plugin extends sbt.Plugin {
def printAsciiGraphTask =
(streams, asciiGraph) map (_.log.info(_))
def dependencyGraphMLTask =
def dependencyGraphMLTask(config: Configuration) =
(ivyReport, target, streams) map { (report, target, streams) =>
val resultFile = target / "dependencies.graphml"
val resultFile = target / "dependencies-%s.graphml".format(config.toString)
IvyGraphMLDependencies.transform(report.getAbsolutePath, resultFile.getAbsolutePath)
streams.log.info("Wrote dependency graph to '%s'" format resultFile)
resultFile