You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kafka.apache.org by ju...@apache.org on 2013/04/17 17:20:52 UTC
git commit: kafka-843; (addendum) Re-add the release-zip sbt target;
patched by Cosmin Lehene; reviewed by Jun Rao
Updated Branches:
refs/heads/0.8 b29b6296a -> c5bb1d499
kafka-843; (addendum) Re-add the release-zip sbt target; patched by Cosmin Lehene; reviewed by Jun Rao
Project: http://git-wip-us.apache.org/repos/asf/kafka/repo
Commit: http://git-wip-us.apache.org/repos/asf/kafka/commit/c5bb1d49
Tree: http://git-wip-us.apache.org/repos/asf/kafka/tree/c5bb1d49
Diff: http://git-wip-us.apache.org/repos/asf/kafka/diff/c5bb1d49
Branch: refs/heads/0.8
Commit: c5bb1d49942fd94a1ead938567031f9faaeacfbd
Parents: b29b629
Author: Cosmin Lehene <cl...@adobe.com>
Authored: Wed Apr 17 08:20:30 2013 -0700
Committer: Jun Rao <ju...@gmail.com>
Committed: Wed Apr 17 08:20:30 2013 -0700
----------------------------------------------------------------------
project/Build.scala | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/kafka/blob/c5bb1d49/project/Build.scala
----------------------------------------------------------------------
diff --git a/project/Build.scala b/project/Build.scala
index 11ccb75..f177215 100644
--- a/project/Build.scala
+++ b/project/Build.scala
@@ -30,9 +30,9 @@ object KafkaBuild extends Build {
scalacOptions ++= Seq("-deprecation", "-unchecked", "-g:none"),
crossScalaVersions := Seq("2.8.0","2.8.2", "2.9.1", "2.9.2"),
scalaVersion := "2.8.0",
- buildNumber := System.getProperty("build.number", "SNAPSHOT"),
- buildNumber <<= buildNumber { build => if (build == "") "SNAPSHOT" else build},
- version <<= buildNumber { build => "0.8-" + build},
+ version := "0.8.0-SNAPSHOT",
+ buildNumber := System.getProperty("build.number", ""),
+ version <<= (buildNumber, version) { (build, version) => if (build == "") version else version + "+" + build},
releaseName <<= (name, version, scalaVersion) {(name, version, scalaVersion) => name + "_" + scalaVersion + "-" + version},
javacOptions ++= Seq("-Xlint:unchecked", "-source", "1.5"),
parallelExecution in Test := false, // Prevent tests from overrunning each other
@@ -99,12 +99,13 @@ object KafkaBuild extends Build {
IO.copyDirectory(file("config"), destination / "config")
IO.copyDirectory(file("bin"), destination / "bin")
for {file <- (destination / "bin").listFiles} { file.setExecutable(true, true) }
- IO.zip(Path.allSubpaths(target/"RELEASE"), target/"%s.zip".format(releaseName))
}
val releaseZip = TaskKey[Unit]("release-zip", "Creates a deployable zip file with dependencies, config, and scripts.")
val releaseZipTask = releaseZip <<= (release, target, releaseName in core) map { (release, target, releaseName) =>
- IO.zip(Path.allSubpaths(target/"RELEASE"), target/ "RELEASE" / "%s.zip".format(releaseName))
+ val zipPath = target / "RELEASE" / "%s.zip".format(releaseName)
+ IO.delete(zipPath)
+ IO.zip((target/"RELEASE" ** releaseName ***) x relativeTo(target/"RELEASE"), zipPath)
}
val releaseTar = TaskKey[Unit]("release-tar", "Creates a deployable tar.gz file with dependencies, config, and scripts.")