Commits

Meikel Brandmeyer  committed 5bb82b5

Add property loading info in the base plugin

  • Participants
  • Parent commits 3a622cb

Comments (0)

Files changed (1)

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

 import org.gradle.api.plugins.MavenPlugin
 import org.gradle.api.tasks.Upload
 
+import java.io.InputStreamReader
+import java.util.Properties
+
 public class ClojureBasePlugin implements Plugin<Project> {
     public void apply(Project project) {
         project.apply plugin: JavaPlugin.class
         configureClojarsUpload(project)
     }
 
+    private Properties getProperties() {
+        Properties props = new Properties()
+        InputStreamReader propStream =
+            new InputStreamReader(this.class.getResourceAsStream("clojuresque.properties"), "UTF-8")
+
+        try {
+            props.load(propStream)
+        } finally {
+            propStream.close()
+        }
+
+        return props
+    }
+
     private void configureConfigurations(Project project) {
         project.configurations {
             clojuresque {