-
Notifications
You must be signed in to change notification settings - Fork 1k
Closed
Labels
Description
Currently the packageBin task is the only way to get hold of the jar output from a project/config. (actually (artifactPath in Compile in packageBin).value would be enough but it amounts to the same).
However, it is often useful to know where the file is going to be without necessarily invoking the compilation (e.g. projects that are compiler plugins and need to be referenced by IDEs, caching strategies).
Proposed implementation:
val packageBinFile = SettingKey[File](
"packageBinFile",
"The (eventual) location of the packageBin."
)
def packageBinFileSetting = Def.setting {
val append = configuration.value match {
case Compile => ""
case Test => "-tests"
case _ => "-" + configuration.value.name
}
crossTarget.value / s"${projectID.value.name}_${scalaBinaryVersion.value}-${projectID.value.revision}$append.jar"
}
Reactions are currently unavailable