forked from rtimush/sbt-updates
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproguard.sbt
32 lines (22 loc) · 1008 Bytes
/
proguard.sbt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
ProguardPlugin.proguardSettings
proguardLibraryJars <++= (dependencyClasspath in Compile, dependencyClasspath in Embedded) map {
(ccp, rcp) => ccp.files filterNot rcp.files.toSet
}
proguardInJars <++= (dependencyClasspath in Embedded) map (_.files)
proguardLibraryJars <++= (scalaInstance) map { (si) => Seq(si.libraryJar) }
proguardInJars := Seq()
proguardDefaultArgs := Seq()
proguardOptions ++= Seq(
"-dontwarn",
"-dontnote",
"-dontoptimize",
"-keep class com.timushev.sbt.updates.**",
"-keepclassmembers class * { ** MODULE$; }",
"-repackageclasses 'com.timushev.sbt.updates.libs'"
)
SbtUpdatesBuild.publishMinJar <<= (proguard, minJarPath) map { (_, jar) => jar }
packagedArtifact in (Compile, packageBin) <<= (packagedArtifact in (Compile, packageBin), SbtUpdatesBuild.publishMinJar) map {
case ((art, _), jar) => (art, jar)
}
dependencyClasspath in Compile <++= dependencyClasspath in Embedded
dependencyClasspath in Test <++= dependencyClasspath in Embedded