mirror of https://github.com/sbt/sbt.git
Moved Milli._ to IO.
This commit is contained in:
parent
ccf149e8bf
commit
d03dfb3981
|
|
@ -9,7 +9,7 @@ import java.io.File
|
|||
import sbt.io.{ IO, Path }
|
||||
import sbt.io.syntax._
|
||||
import Path._
|
||||
import sbt.io.Milli.getModifiedTime
|
||||
import sbt.io.IO.getModifiedTime
|
||||
|
||||
class FileCommands(baseDirectory: File) extends BasicStatementHandler {
|
||||
lazy val commands = commandMap
|
||||
|
|
@ -68,8 +68,7 @@ class FileCommands(baseDirectory: File) extends BasicStatementHandler {
|
|||
def newer(a: String, b: String): Unit = {
|
||||
val pathA = fromString(a)
|
||||
val pathB = fromString(b)
|
||||
val isNewer = pathA.exists && (!pathB.exists || getModifiedTime(pathA) > getModifiedTime(
|
||||
pathB))
|
||||
val isNewer = pathA.exists && (!pathB.exists || getModifiedTime(pathA) > getModifiedTime(pathB))
|
||||
if (!isNewer) {
|
||||
scriptError(s"$pathA is not newer than $pathB")
|
||||
}
|
||||
|
|
|
|||
|
|
@ -8,7 +8,7 @@ import scala.util.control.NonFatal
|
|||
import sbt.io.Hash
|
||||
import sjsonnew.{ Builder, JsonFormat, Unbuilder, deserializationError }
|
||||
import CacheImplicits._
|
||||
import sbt.io.Milli.getModifiedTime
|
||||
import sbt.io.IO.getModifiedTime
|
||||
|
||||
sealed trait FileInfo { def file: File }
|
||||
sealed trait HashFileInfo extends FileInfo { def hash: List[Byte] }
|
||||
|
|
|
|||
|
|
@ -3,7 +3,7 @@ package sbt.util
|
|||
import sjsonnew.shaded.scalajson.ast.unsafe._
|
||||
import sjsonnew._, support.scalajson.unsafe._
|
||||
import sbt.internal.util.UnitSpec
|
||||
import sbt.io.Milli.getModifiedTime
|
||||
import sbt.io.IO.getModifiedTime
|
||||
|
||||
class FileInfoSpec extends UnitSpec {
|
||||
val file = new java.io.File(".").getAbsoluteFile
|
||||
|
|
|
|||
Loading…
Reference in New Issue