mirror of https://github.com/sbt/sbt.git
clean-plugins task and web/jsp test fix
This commit is contained in:
parent
85bbd7a29d
commit
8cc12a0068
|
|
@ -563,7 +563,7 @@ trait ReflectiveModules extends Project
|
|||
trait ReflectiveProject extends ReflectiveModules with ReflectiveTasks with ReflectiveMethods
|
||||
|
||||
/** This Project subclass is used to contain other projects as dependencies.*/
|
||||
class ParentProject(val info: ProjectInfo) extends BasicDependencyProject
|
||||
class ParentProject(val info: ProjectInfo) extends BasicDependencyProject with Cleanable
|
||||
{
|
||||
def dependencies: Iterable[Project] = info.dependencies ++ subProjects.values.toList
|
||||
/** The directories to which a project writes are listed here and is used
|
||||
|
|
|
|||
|
|
@ -8,32 +8,12 @@ import java.io.File
|
|||
import java.util.jar.{Attributes, Manifest}
|
||||
import scala.collection.mutable.ListBuffer
|
||||
|
||||
trait SimpleScalaProject extends ExecProject
|
||||
trait Cleanable extends Project
|
||||
{
|
||||
def errorTask(message: String) = task{ Some(message) }
|
||||
|
||||
trait CleanOption extends ActionOption
|
||||
case class ClearAnalysis(analysis: TaskAnalysis[_, _, _]) extends CleanOption
|
||||
case class Preserve(paths: PathFinder) extends CleanOption
|
||||
|
||||
case class CompileOption(val asString: String) extends ActionOption
|
||||
case class JavaCompileOption(val asString: String) extends ActionOption
|
||||
|
||||
val Deprecation = CompileOption(CompileOptions.Deprecation)
|
||||
val ExplainTypes = CompileOption("-explaintypes")
|
||||
val Optimize = CompileOption("-optimise")
|
||||
def Optimise = Optimize
|
||||
val Verbose = CompileOption(CompileOptions.Verbose)
|
||||
val Unchecked = CompileOption(CompileOptions.Unchecked)
|
||||
val DisableWarnings = CompileOption("-nowarn")
|
||||
def target(target: Target.Value) = CompileOption("-target:" + target)
|
||||
object Target extends Enumeration
|
||||
{
|
||||
val Java1_5 = Value("jvm-1.5")
|
||||
val Java1_4 = Value("jvm-1.4")
|
||||
val Msil = Value("msil")
|
||||
}
|
||||
|
||||
def cleanTask(paths: PathFinder, options: CleanOption*): Task =
|
||||
cleanTask(paths, options)
|
||||
def cleanTask(paths: PathFinder, options: => Seq[CleanOption]): Task =
|
||||
|
|
@ -53,6 +33,30 @@ trait SimpleScalaProject extends ExecProject
|
|||
pathClean orElse restored
|
||||
}
|
||||
}
|
||||
|
||||
lazy val cleanPlugins = cleanTask(info.pluginsOutputPath +++ info.pluginsManagedSourcePath +++ info.pluginsManagedDependencyPath)
|
||||
}
|
||||
trait SimpleScalaProject extends ExecProject with Cleanable
|
||||
{
|
||||
def errorTask(message: String) = task{ Some(message) }
|
||||
|
||||
case class CompileOption(val asString: String) extends ActionOption
|
||||
case class JavaCompileOption(val asString: String) extends ActionOption
|
||||
|
||||
val Deprecation = CompileOption(CompileOptions.Deprecation)
|
||||
val ExplainTypes = CompileOption("-explaintypes")
|
||||
val Optimize = CompileOption("-optimise")
|
||||
def Optimise = Optimize
|
||||
val Verbose = CompileOption(CompileOptions.Verbose)
|
||||
val Unchecked = CompileOption(CompileOptions.Unchecked)
|
||||
val DisableWarnings = CompileOption("-nowarn")
|
||||
def target(target: Target.Value) = CompileOption("-target:" + target)
|
||||
object Target extends Enumeration
|
||||
{
|
||||
val Java1_5 = Value("jvm-1.5")
|
||||
val Java1_4 = Value("jvm-1.4")
|
||||
val Msil = Value("msil")
|
||||
}
|
||||
}
|
||||
trait ScalaProject extends SimpleScalaProject with FileTasks with MultiTaskProject with Exec
|
||||
{
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
<html>
|
||||
<body>
|
||||
<% out.println(" Hello World!"); %>
|
||||
<% out.println(" Hello World 2!"); %>
|
||||
</body>
|
||||
</html>
|
||||
Loading…
Reference in New Issue