Commits

Meikel Brandmeyer  committed 4fdd55c Merge

Merge v1.5.4

  • Participants
  • Parent commits 34ffb9f, 187fcb3

Comments (0)

Files changed (9)

 c92d98bdf192408de62f9ffbdd4867f1036f6082 v1.4.4
 754e8708574a87dba6caf5e5378682e123b9044c v1.4.5
 55713b80d7632926d86511c31804b5b90c27ae5b v1.5.0
+5b10b0793d182590eae0846c208ab7de9b8cfd9e v1.5.1
+ab1c08a1b455839a35353e00201e1659bd9cf381 v1.5.2
+9ad5c08355ba5c19e01ba0e5211ffaf8f340f4c5 v1.5.3
+40f259618c828be99e8c67ecd7b90d07bffac43e v1.5.4

File build.gradle

 subprojects {
     group = 'clojuresque'
     version = '1.6.0-SNAPSHOT'
+
+    ext.isReleaseVersion = !version.endsWith("SNAPSHOT")
+
+    apply {
+        plugin 'signing'
+        plugin 'maven'
+    }
+
+    repositories {
+        maven { url "http://127.0.0.1:8080/repository/internal" }
+        mavenCentral()
+    }
 }
 
 project(':clojuresque') {
-    apply plugin: 'groovy'
+    apply {
+        plugin 'groovy'
+    }
 
     dependencies {
         compile gradleApi()
 }
 
 project(':clojuresque-runtime') {
-    apply plugin: 'java'
-
-    repositories {
-        mavenCentral()
+    apply {
+        plugin 'java'
     }
 
     dependencies {
-        compile 'org.clojure:clojure:[1.2,1.4)'
+        compile 'org.clojure:clojure:[1.2,1.5)'
     }
 }
 
 project(':scriptoresque') {
-    apply plugin: 'groovy'
-
-    repositories {
-        mavenCentral()
+    apply {
+        plugin 'groovy'
     }
 
     dependencies {
 }
 
 project(':scriptoresque-runtime') {
-    apply plugin: 'java'
-
-    repositories {
-        mavenCentral()
+    apply {
+        plugin 'java'
     }
 
     dependencies {
 }
 
 subprojects {
-    apply plugin: 'maven'
+    configurations {
+        deployerJars
+    }
 
-    uploadArchives.doLast {
-        String pomFile = project.buildDir.path + "/" +
-            project.mavenPomDir.name + "/" +
-            project.name + "-" + project.version + ".xml"
+    dependencies {
+        deployerJars 'org.apache.maven.wagon:wagon-http-lightweight:2.2'
+    }
 
-        project.pom().writeTo(pomFile)
+    uploadArchives {
+        repositories {
+            mavenDeployer {
+                configuration = configurations.deployerJars
+                repository(url: "https://clojars.org/repo") {
+                    authentication(
+                        userName: project.properties["clojuresque.clojars.username"],
+                        password: project.properties["clojuresque.clojars.password"]
+                    )
+                }
+                pom.project {
+                    licenses {
+                        license {
+                            name 'MIT License'
+                            url 'http://opensource.org/licenses/MIT'
+                            distribution 'repo'
+                        }
+                    }
+                    description "A Clojure plugin for the Gradle build system"
+                    url "http://bitbucket.org/clojuresque/clojuresque"
+                    scm {
+                        connection 'scm:hg:hg@bitbucket.org:clojuresque/clojuresque'
+                        developerConnection 'scm:hg:hg@bitbucket.org:clojuresque/clojuresque'
+                        url 'hg@bitbucket.org:clojuresque/clojuresque'
+                    }
+                }
+                beforeDeployment { signing.signPom(it) }
+            }
+        }
+    }
 
-        project.exec {
-            commandLine(
-                '/usr/bin/scp',
-                pomFile,
-                project.jar.archivePath.path,
-                'clojars@clojars.org:'
-            )
-        }
+    signing {
+        sign configurations.archives
     }
 }
 

File clojuresque/src/main/groovy/clojuresque/ClojureBasePlugin.groovy

 
             sourceSet.convention.plugins.clojure = clojureSourceSet
             sourceSet.clojure.srcDirs = [ String.format("src/%s/clojure", sourceSet.name) ]
-            sourceSet.resources.filter.exclude("**/*.clj")
             sourceSet.allSource.source(clojureSourceSet.clojure)
         }
     }

File clojuresque/src/main/groovy/clojuresque/ClojureCompileTask.groovy

 
 
         project.clojureexec {
-            this.jvmOptions()
+            project.configure delegate, this.jvmOptions
             systemProperties "clojure.compile.path": this.destinationDir.path
             classpath = project.files(
                 this.clojureRoots.srcDirs,

File clojuresque/src/main/groovy/clojuresque/ClojurePlugin.groovy

 /*-
- * Copyright 2009,2010 © Meikel Brandmeyer.
+ * Copyright 2009-2012 © Meikel Brandmeyer.
  * All rights reserved.
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
     }
 
     private void configureUberjar(Project project) {
-        project.tasks.withType(Jar.class).each { jar ->
-            project.tasks.add(name: "uber" + jar.name, type: Jar.class) {
+        project.tasks.withType(Jar.class).asMap.each { name, jar ->
+            project.tasks.add(name: "uber" + name, type: Jar.class) {
                 description =
                     'Constructs a jar with all runtime dependencies included'
                 dependsOn jar.source, project.configurations.runtime
                     project.configurations.runtime.each {
                         from project.zipTree(it)
                         exclude 'META-INF/MANIFEST.MF'
+                        exclude 'META-INF/*.SF'
+                        exclude 'META-INF/*.DSA'
+                        exclude 'META-INF/*.RSA'
                     }
                     from jar.source
                 }

File clojuresque/src/main/groovy/clojuresque/ClojurePluginConvention.groovy

 
 import org.gradle.api.Project
 import org.gradle.process.ExecResult
-import org.gradle.util.ConfigureUtil
 
 import groovy.lang.Closure
 
     }
 
     public ExecResult clojureexec(Closure spec) {
-        ClojureExecAction action = ConfigureUtil.configure(spec,
-            new ClojureExecAction(project.fileResolver, project.configurations.clojuresque))
+        ClojureExecAction action = project.configure(
+            new ClojureExecAction(project.fileResolver,
+                project.configurations.clojuresque),
+            spec
+        )
         return action.execute()
     }
 }

File clojuresque/src/main/groovy/clojuresque/ClojureTestTask.groovy

     @TaskAction
     public void runTests() {
         project.clojureexec {
-            this.jvmOptions()
+            project.configure delegate, this.jvmOptions
             classpath = project.files(
                 this.testRoots.srcDirs,
                 this.classesDir,

File clojuresque/src/main/groovy/clojuresque/ClojureUploadConvention.groovy

 
     public void clojarsDeploy() {
         upload.doLast {
-            String pomName = project.buildDirName + "/" +
-                project.mavenPomDir.name + "/" +
+            String pomName = project.buildDir.path + "/" +
+                project.mavenPomDir.path + "/" +
                 "pom-" + upload.configuration.name + ".xml"
 
             project.pom().writeTo(pomName)

File clojuresque/src/main/java/clojuresque/ClojureExecAction.java

 import org.gradle.process.internal.ExecHandle;
 import org.gradle.process.internal.JavaExecAction;
 import org.gradle.process.internal.JavaExecHandleBuilder;
-import org.gradle.util.GUtil;
 
 import java.io.File;
 import java.util.ArrayList;
     @Override
     public List<String> getAllJvmArgs() {
         List<String> allArgs = super.getAllJvmArgs();
-        String driver = GUtil.join(driverClasspath.getFiles(), File.pathSeparator);
+        String driver = driverClasspath.getAsPath();
 
         int pos = allArgs.indexOf("-cp") + 1;
         if (pos > 0) {