Browse Source

Fix duplicate jar contents.

Don't include the version.config from build as well as the one we're
generating.

Don't include dependencies etc twice in fat jars.
pull/166/head
Chris Smith 9 years ago
parent
commit
c182f76649
1 changed files with 4 additions and 8 deletions
  1. 4
    8
      build.gradle

+ 4
- 8
build.gradle View File

@@ -189,6 +189,8 @@ jar {
189 189
     outputs.file "dist/DMDirc.jar"
190 190
     dependsOn createVersionConfig
191 191
 
192
+    exclude 'com/dmdirc/version.config'
193
+
192 194
     from("$buildDir/version.config") {
193 195
         into 'com/dmdirc/'
194 196
     }
@@ -219,20 +221,14 @@ task('fatjar', type: Jar) {
219 221
         rename 'fat.version.config', 'version.config'
220 222
     }
221 223
 
222
-    from { configurations.bundle.collect { it.isDirectory() ? it : zipTree(it) } } {
223
-        exclude 'META-INF/**'
224
-    }
225
-
226 224
     into('plugins') {
227 225
         from configurations.plugin
228 226
         rename '(.*?)-.*(\\.jar)', '$1$2'
229 227
     }
230 228
 
231
-    manifest {
232
-        attributes 'Main-Class': 'com.dmdirc.Main'
229
+    with jar {
230
+        exclude 'com/dmdirc/version.config'
233 231
     }
234
-
235
-    with jar
236 232
 }
237 233
 
238 234
 buildscript {

Loading…
Cancel
Save