From bc9dc386625021fec517f2dbf0644ccafe1e32c2 Mon Sep 17 00:00:00 2001 From: Li Haoyi Date: Mon, 5 Nov 2018 03:00:04 +0800 Subject: WIP migrating over from `ammonite.ops` to `os` module. __.compile works, haven't run tests yet --- main/test/resources/examples/javac/build.sc | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'main/test/resources/examples/javac/build.sc') diff --git a/main/test/resources/examples/javac/build.sc b/main/test/resources/examples/javac/build.sc index 0783ac17..c45a6e2d 100644 --- a/main/test/resources/examples/javac/build.sc +++ b/main/test/resources/examples/javac/build.sc @@ -1,4 +1,3 @@ -import ammonite.ops._ import mill.T import mill.eval.JavaCompileJarTests.compileAll import mill.eval.PathRef @@ -14,10 +13,10 @@ def resourceRootPath = millSourcePath / 'resources // resourceRoot ----> jar def sourceRoot = T.sources{ sourceRootPath } def resourceRoot = T.sources{ resourceRootPath } -def allSources = T{ sourceRoot().flatMap(p => ls.rec(p.path)).map(PathRef(_)) } +def allSources = T{ sourceRoot().flatMap(p => os.walk(p.path)).map(PathRef(_)) } def classFiles = T{ compileAll(allSources()) } def jar = T{ Jvm.createJar(Loose.Agg(classFiles().path) ++ resourceRoot().map(_.path)) } def run(mainClsName: String) = T.command{ - %%('java, "-cp", classFiles().path, mainClsName)(T.ctx().dest) + os.proc('java, "-cp", classFiles().path, mainClsName).call(T.ctx().dest) } -- cgit v1.2.3