Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge pull request #3 from FranklinChen/latest-gradle-version

@FranklinkChen fixed a variety of deprecations and a couple of errors in the examples. Massive thanks to him.
  • Loading branch information...
commit 351f31f1cdede84233b977e67031720177144aab 2 parents 7b91f5e + 70102b2
authored September 15, 2012
4  tasks-jar-task/build.gradle
@@ -6,5 +6,5 @@ task customJar(type: Jar) {
6 6
   }
7 7
   archiveName = 'hello.jar'
8 8
   destinationDir = file("${buildDir}/jars")
9  
-  from sourceSets.main.classes
10  
-}
  9
+  from sourceSets.main.output
  10
+}
2  tasks-jar-task/run-example.bsh
... ...
@@ -1,2 +1,2 @@
1 1
 #!/bin/bash
2  
-gradle build
  2
+gradle customJar
2  tasks-javaexec-task/build.gradle
@@ -5,7 +5,7 @@ repositories {
5 5
 }
6 6
 
7 7
 dependencies {
8  
-  runtime 'commons-codec:commons-codec:1.5'
  8
+  compile 'commons-codec:commons-codec:1.5'
9 9
 }
10 10
 
11 11
 task encode(type: JavaExec, dependsOn: classes) {
2  tasks-javaexec-task/run-example.bsh
... ...
@@ -1,2 +1,2 @@
1 1
 #!/bin/bash
2  
-gradle build
  2
+gradle encode
6  tasks-task-lab/dynamic.gradle
... ...
@@ -1,9 +1,9 @@
1 1
 task copyFiles {
2 2
   // Find files from wherever, copy them
3 3
   // (then hardcode a list of files for illustration)
4  
-  fileManifest = [ 'data.csv', 'config.json' ]
  4
+  ext.fileManifest = [ 'data.csv', 'config.json' ]
5 5
 }
6 6
 
7 7
 task createArtifact(dependsOn: copyFiles) << {
8  
-  println "FILES IN MANIFEST: ${copyFiles.fileManifest}"
9  
-}
  8
+  println "FILES IN MANIFEST: ${copyFiles.ext.fileManifest}"
  9
+}
1  tasks-task-lab/run-example.bsh
@@ -6,4 +6,5 @@ gradle -b dynamic.gradle                createArtifact
6 6
 gradle -b enabled.gradle                sendEmails
7 7
 gradle -b logging.gradle                logLevel
8 8
 gradle -b onlyIf.gradle                 loadTestData
  9
+gradle -Dload.data=true -b onlyIf.gradle                 loadTestData
9 10
 gradle -b path.gradle                   echoMyPath

0 notes on commit 351f31f

Please sign in to comment.
Something went wrong with that request. Please try again.