aboutsummaryrefslogtreecommitdiff
path: root/stage2/Lib.scala
diff options
context:
space:
mode:
authorChristopher Vogt <oss.nsp@cvogt.org>2016-07-06 21:36:28 -0400
committerChristopher Vogt <oss.nsp@cvogt.org>2016-07-06 21:44:29 -0400
commitbb7cb00014a0355b067c03423723a309c0acbb87 (patch)
tree61d70de9648cce379adbd1fa977c995201fb972a /stage2/Lib.scala
parentbc2231720d3620b5e0459fa12c467bf675fcfdf5 (diff)
downloadcbt-bb7cb00014a0355b067c03423723a309c0acbb87.tar.gz
cbt-bb7cb00014a0355b067c03423723a309c0acbb87.tar.bz2
cbt-bb7cb00014a0355b067c03423723a309c0acbb87.zip
publish local support
Diffstat (limited to 'stage2/Lib.scala')
-rw-r--r--stage2/Lib.scala12
1 files changed, 12 insertions, 0 deletions
diff --git a/stage2/Lib.scala b/stage2/Lib.scala
index a060ac6..f769c44 100644
--- a/stage2/Lib.scala
+++ b/stage2/Lib.scala
@@ -367,6 +367,18 @@ final class Lib(logger: Logger) extends Stage1Lib(logger) with Scaffold{
}
}
+ def publishLocal( sourceFiles: Seq[File], artifacts: Seq[File], mavenCache: File, releaseFolder: String ): Unit = {
+ if(sourceFiles.nonEmpty){
+ val targetDir = mavenCache ++ releaseFolder.stripSuffix("/")
+ targetDir.mkdirs
+ artifacts.foreach{ a =>
+ val target = targetDir ++ ("/" ++ a.getName)
+ System.err.println(blue("publishing ") ++ target.getPath)
+ Files.copy( a.toPath, target.toPath, StandardCopyOption.REPLACE_EXISTING )
+ }
+ }
+ }
+
def publishSigned( sourceFiles: Seq[File], artifacts: Seq[File], url: URL, credentials: Option[String] = None ): Unit = {
// TODO: make concurrency configurable here
if(sourceFiles.nonEmpty){