mirror of https://github.com/sbt/sbt.git
Custom implementation of Streams can be bound to Keys.stateStreams in State.
This commit is contained in:
parent
f30953ea4d
commit
29a26a13ab
|
|
@ -75,7 +75,7 @@ object BuildStreams
|
|||
final val StreamsDirectory = "streams"
|
||||
|
||||
def mkStreams(units: Map[URI, LoadedBuildUnit], root: URI, data: Settings[Scope]): State => Streams = s =>
|
||||
std.Streams( path(units, root, data), displayFull, LogManager.construct(data, s) )
|
||||
s get Keys.stateStreams getOrElse std.Streams( path(units, root, data), displayFull, LogManager.construct(data, s) )
|
||||
|
||||
def path(units: Map[URI, LoadedBuildUnit], root: URI, data: Settings[Scope])(scoped: ScopedKey[_]): File =
|
||||
resolvePath( projectPath(units, root, scoped, data), nonProjectPath(scoped) )
|
||||
|
|
|
|||
|
|
@ -327,6 +327,7 @@ object Keys
|
|||
val (executionRoots, dummyRoots)= dummy[Seq[ScopedKey[_]]]("execution-roots", "The list of root tasks for this task execution. Roots are the top-level tasks that were directly requested to be run.")
|
||||
val (state, dummyState) = dummy[State]("state", "Current build state.")
|
||||
val (streamsManager, dummyStreamsManager) = dummy[Streams]("streams-manager", "Streams manager, which provides streams for different contexts.")
|
||||
val stateStreams = AttributeKey[Streams]("streams-manager", "Streams manager, which provides streams for different contexts. Setting this on State will override the default Streams implementation.")
|
||||
val resolvedScoped = Def.resolvedScoped
|
||||
val pluginData = TaskKey[PluginData]("plugin-data", "Information from the plugin build needed in the main build definition.", DTask)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue