diff build.gradle @ 453:7b883bf03b14

Artifacts upload using gradle build
author Artem Tikhomirov <tikhomirov.artem@gmail.com>
date Wed, 13 Jun 2012 18:18:37 +0200
parents 7dcc920e2d57
children 55e9588b84b8
line wrap: on
line diff
--- a/build.gradle	Tue Jun 12 23:32:12 2012 +0200
+++ b/build.gradle	Wed Jun 13 18:18:37 2012 +0200
@@ -1,6 +1,6 @@
 def isRelease = false
 
-  version = '0.9.0'
+  version = '0.9.0-SNAPSHOT'
   description = 'Pure Java API and Toolkit for Mercurial DVCS'
   group = 'org.tmatesoft.hg4j'
   
@@ -36,18 +36,19 @@
     mavenCentral()
   }
   
+  configurations {
+    deployJars
+  }
+  
   dependencies {
     testCompile 'junit:junit:4.8.2'
     cliCompile 'junit:junit:4.8.2'
     cliCompile files(sourceSets.main.output) {
       builtBy compileJava
-    } 
+    }
+    deployJars "org.apache.maven.wagon:wagon-http:1.0-beta-2"
   }
-  
-  configurations {
-    deployJars
-  }
-  
+    
   def sharedMetaInf = {
     from project.file('COPYING')
   }
@@ -79,6 +80,7 @@
   
   install {
     configuration = configurations.deployJars
+/*
     repositories.mavenDeployer {
       addFilter('f1') { artifact, file ->
          println file.name
@@ -98,7 +100,20 @@
          fname.endsWith(version)
       }
     }
+*/
   }
+  
+  uploadArchives {
+    configuration = configurations.deployJars
+    repositories {
+        mavenDeployer {
+            configuration = configurations.deployJars
+            repository(url: "http://maven.tmatesoft.com/content/repositories/snapshots/") {
+              authentication(userName: "", password: "")
+            }
+        }
+    }
+}
 
   test {
 // <property name="test-repos-root" value="${java.io.tmpdir}/hg4j-tests/"/>