Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

drop proguard for assembly, move to sbt 0.12

  • Loading branch information...
commit dc4efef8999418155f7e60b59a759b24728fc0b2 1 parent f6836e3
@ymasory authored
View
16 README.md
@@ -1,19 +1,25 @@
# sbt-prototype is the starting point for all my projects #
-Warning: you *must* use sbt version 0.11.3-2 or higher to launch this project. If you use a lower version sbt won't be able to switch to the right version. If you use a higher version (like say, 0.12), no sweat, it will automatically download 0.11.3-2 for you. This prototype won't move to 0.12 until all the needed plugins are updated.
+Warning: you *must* use sbt version 0.11.3-2 or higher to launch this project. After that sbt will automatically retrieve the correct version of sbt all by itself.
*Please let me know if any software is out of date. That includes scala version, sbt version, and plugin versions.*
## Features ##
### sbt plugins ###
-- **[xsbt-proguard-plugin](https://github.com/siasia/xsbt-proguard-plugin)**. Generate an executable jar of your project. **NOTE: CURRENTLY WAITING FOR SBT 0.12 UPDATE FOR THIS PLUGIN**
+- **[sbt-assembly](https://github.com/sbt/sbt-assembly)**. Generate a single (executable) jar of your project.
```
$ sbt
-> proguard
-[success] Total time: 19 s, completed May 26, 2012 1:24:33 PM
+> assembly
+[info] Including scalaz-core_2.9.2-7.0.0-M2.jar
+[info] Including scalaz-effect_2.9.2-7.0.0-M2.jar
+[info] Including scala-library.jar
+[info] Merging 'META-INF/MANIFEST.MF' with strategy 'discard'
+[info] Packaging /Users/yuvi/workspace/ymasory/sbt-prototype/target/prototype-project-assembly-1.0.0-SNAPSHOT.jar ...
+[info] Done packaging.
+[success] Total time: 11 s, completed Aug 16, 2012 1:00:42 AM
> exit
-$ java -jar ./target/scala-2.9.2/prototype-project_2.9.2-1.0.0-SNAPSHOT.min.jar
+$ java -jar target/prototype-project-assembly-1.0.0-SNAPSHOT.jar
hello, prototype-project v1.0.0-SNAPSHOT running with Scala v2.9.2 on sbt v0.11.3
```
View
20 build.sbt
@@ -49,24 +49,22 @@ logLevel in compile := Level.Warn
traceLevel := 5
-//proguard-plugin
-seq(ProguardPlugin.proguardSettings :_*)
+//assembly plugin
+mainClass in AssemblyKeys.assembly := Some("com.example.Main")
-proguardOptions ++= Seq (
- "-dontshrink -dontoptimize -dontobfuscate -dontpreverify -dontnote " +
- "-ignorewarnings",
- keepAllScala
-)
+assemblySettings
+
+test in AssemblyKeys.assembly := {}
-//dependecy-graph-plugin
-net.virtualvoid.sbt.graph.Plugin.graphSettings
+//dependecy graph plugin (waiting for sbt 0.12.0 update)
+// net.virtualvoid.sbt.graph.Plugin.graphSettings
-//start-script-plugin
+//start script plugin
seq(
com.typesafe.startscript.StartScriptPlugin.startScriptForClassesSettings: _*
)
-//buildinfo-plugin
+//buildinfo plugin
buildInfoSettings
sourceGenerators in Compile <+= buildInfo
View
2  project/build.properties
@@ -1 +1 @@
-sbt.version=0.11.3-2
+sbt.version=0.12.0
View
17 project/plugins.sbt
@@ -1,23 +1,18 @@
resolvers ++= Seq(
- "jgit-repo" at "http://download.eclipse.org/jgit/maven",
- Resolver.url(
- "scalasbt",
- new URL("http://scalasbt.artifactoryonline.com/scalasbt/sbt-plugin-releases")
- )(Resolver.ivyStylePatterns)
-)
-
-libraryDependencies ++= Seq ( //note old scala and sbt versions
- "com.github.siasia" % "xsbt-proguard-plugin_2.9.1" % "0.11.2-0.1.2"
+ "jgit-repo" at "http://download.eclipse.org/jgit/maven"
)
addSbtPlugin("com.jsuereth" % "sbt-git-plugin" % "0.4")
addSbtPlugin("com.eed3si9n" % "sbt-man" % "0.1.0")
-addSbtPlugin("net.virtual-void" % "sbt-dependency-graph" % "0.6.0")
+//waiting for sbt 0.12.0 update
+// addSbtPlugin("net.virtual-void" % "sbt-dependency-graph" % "0.6.0")
-addSbtPlugin("com.typesafe.startscript" % "xsbt-start-script-plugin" % "0.5.2")
+addSbtPlugin("com.typesafe.startscript" % "xsbt-start-script-plugin" % "0.5.3")
addSbtPlugin("com.eed3si9n" % "sbt-buildinfo" % "0.1.2")
addSbtPlugin("com.jsuereth" % "xsbt-gpg-plugin" % "0.6")
+
+addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.8.3")
Please sign in to comment.
Something went wrong with that request. Please try again.