mirror of
https://github.com/ethauvin/kobalt.git
synced 2025-04-26 08:27:12 -07:00
Introduce build listeners and build report contributors.
This commit is contained in:
parent
f629b76658
commit
007bb31ee3
7 changed files with 86 additions and 19 deletions
|
@ -213,14 +213,9 @@ private class Main @Inject constructor(
|
|||
// Shutdown all plug-ins
|
||||
plugins.shutdownPlugins()
|
||||
|
||||
// Display timings if requested
|
||||
if (args.profiling) {
|
||||
log(1, "\n" + AsciiArt.horizontalSingleLine + " Timings (in seconds)")
|
||||
runTargetResult.timings.sortedByDescending { it.durationMillis }.forEach {
|
||||
log(1, String.format("%1$10.2f", it.durationMillis.toDouble() / 1000)
|
||||
+ " " + it.taskName)
|
||||
}
|
||||
log(1, "\n")
|
||||
// Run the build report contributors
|
||||
pluginInfo.buildReportContributors.forEach {
|
||||
it.generateReport(Kobalt.context!!)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue