upgrade to gradle 0.9 preview 1
This commit is contained in:
parent
3e12600520
commit
6ed23744fc
38
build.gradle
38
build.gradle
|
@ -2,7 +2,7 @@ import java.text.SimpleDateFormat
|
|||
|
||||
defaultTasks "clean", "release"
|
||||
|
||||
usePlugin BasePlugin
|
||||
apply plugin: 'base'
|
||||
|
||||
archivesBaseName = 'elasticsearch'
|
||||
|
||||
|
@ -69,32 +69,44 @@ task explodedDist(dependsOn: [configurations.distLib], description: 'Builds a mi
|
|||
ant.chmod(dir: "$explodedDistDir/bin", perm: "ugo+rx", includes: "**/*")
|
||||
}
|
||||
|
||||
task zip(type: Zip) {
|
||||
dependsOn explodedDist
|
||||
// classifier = 'all'
|
||||
}
|
||||
|
||||
zip.doFirst {task ->
|
||||
task zip(type: Zip, dependsOn: ['explodedDist']) {
|
||||
zipRootFolder = "$archivesBaseName-${-> version}"
|
||||
task.configure {
|
||||
zipFileSet(dir: explodedDistDir, prefix: zipRootFolder) {
|
||||
from(explodedDistDir) {
|
||||
into zipRootFolder
|
||||
exclude 'bin/*'
|
||||
}
|
||||
zipFileSet(dir: explodedDistDir, prefix: zipRootFolder, fileMode: '775') {
|
||||
from(explodedDistDir) {
|
||||
into zipRootFolder
|
||||
include 'bin/*'
|
||||
exclude 'bin/*.*'
|
||||
fileMode: '775'
|
||||
}
|
||||
zipFileSet(dir: explodedDistDir, prefix: zipRootFolder) {
|
||||
from(explodedDistDir) {
|
||||
into zipRootFolder
|
||||
include 'bin/*.*'
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//zip.doFirst {task ->
|
||||
// task.configure {
|
||||
// zipFileSet(dir: explodedDistDir, prefix: zipRootFolder) {
|
||||
// exclude 'bin/*'
|
||||
// }
|
||||
// zipFileSet(dir: explodedDistDir, prefix: zipRootFolder, fileMode: '775') {
|
||||
// include 'bin/*'
|
||||
// exclude 'bin/*.*'
|
||||
// }
|
||||
// zipFileSet(dir: explodedDistDir, prefix: zipRootFolder) {
|
||||
// include 'bin/*.*'
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
//
|
||||
task release(dependsOn: [zip, ":plugins-attachments:release"]) << {
|
||||
ant.delete(dir: explodedDistDir)
|
||||
}
|
||||
|
||||
task wrapper(type: Wrapper) {
|
||||
gradleVersion = '0.8'
|
||||
gradleVersion = '0.9-preview-1'
|
||||
jarPath = 'gradle'
|
||||
}
|
||||
|
|
Binary file not shown.
|
@ -1,8 +1,8 @@
|
|||
#Sun Dec 13 20:16:46 IST 2009
|
||||
#Fri Apr 02 15:36:16 IDT 2010
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
distributionVersion=0.8
|
||||
distributionVersion=0.9-preview-1
|
||||
zipStorePath=wrapper/dists
|
||||
urlRoot=http\://dist.codehaus.org/gradle
|
||||
distributionName=gradle
|
||||
|
|
|
@ -10,6 +10,8 @@
|
|||
GRADLE_OPTS="$GRADLE_OPTS -Xmx512m"
|
||||
# JAVA_OPTS="$JAVA_OPTS -Xmx512"
|
||||
|
||||
GRADLE_APP_NAME=Gradle
|
||||
|
||||
warn ( ) {
|
||||
echo "${PROGNAME}: $*"
|
||||
}
|
||||
|
@ -60,7 +62,7 @@ if $cygwin ; then
|
|||
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
|
||||
fi
|
||||
|
||||
STARTER_MAIN_CLASS=org.gradle.wrapper.WrapperMain
|
||||
STARTER_MAIN_CLASS=org.gradle.wrapper.GradleWrapperMain
|
||||
CLASSPATH=`dirname "$0"`/gradle/gradle-wrapper.jar
|
||||
WRAPPER_PROPERTIES=`dirname "$0"`/gradle/gradle-wrapper.properties
|
||||
# Determine the Java command to use to start the JVM.
|
||||
|
@ -83,10 +85,15 @@ if [ -z "$JAVA_HOME" ] ; then
|
|||
warn "JAVA_HOME environment variable is not set"
|
||||
fi
|
||||
|
||||
# For Darwin, add GRADLE_APP_NAME to the JAVA_OPTS as -Xdock:name
|
||||
if $darwin; then
|
||||
JAVA_OPTS="$JAVA_OPTS -Xdock:name=$GRADLE_APP_NAME"
|
||||
# we may also want to set -Xdock:image
|
||||
fi
|
||||
|
||||
# For Cygwin, switch paths to Windows format before running java
|
||||
if $cygwin ; then
|
||||
JAVA_HOME=`cygpath --path --mixed "$JAVA_HOME"`
|
||||
TOOLS_JAR=`cygpath --path --mixed "$TOOLS_JAR"`
|
||||
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
|
||||
|
||||
# We build the pattern for arguments to be converted via cygpath
|
||||
|
@ -130,7 +137,6 @@ fi
|
|||
|
||||
"$JAVACMD" $JAVA_OPTS $GRADLE_OPTS \
|
||||
-classpath "$CLASSPATH" \
|
||||
-Dtools.jar="$TOOLS_JAR" \
|
||||
-Dorg.gradle.wrapper.properties="$WRAPPER_PROPERTIES" \
|
||||
$STARTER_MAIN_CLASS \
|
||||
"$@"
|
||||
|
|
|
@ -100,13 +100,12 @@ set CMD_LINE_ARGS=%$
|
|||
:execute
|
||||
@rem Setup the command line
|
||||
|
||||
set STARTER_MAIN_CLASS=org.gradle.wrapper.WrapperMain
|
||||
set STARTER_MAIN_CLASS=org.gradle.wrapper.GradleWrapperMain
|
||||
set CLASSPATH=%DIRNAME%\gradle\gradle-wrapper.jar
|
||||
set WRAPPER_PROPERTIES=%DIRNAME%\gradle\gradle-wrapper.properties
|
||||
set JAVA_EXE=%JAVA_HOME%\bin\java.exe
|
||||
set TOOLS_JAR=%JAVA_HOME%\lib\tools.jar
|
||||
|
||||
set GRADLE_OPTS=%JAVA_OPTS% %GRADLE_OPTS% -Dtools.jar="%TOOLS_JAR%" -Dorg.gradle.wrapper.properties="%WRAPPER_PROPERTIES%"
|
||||
set GRADLE_OPTS=%JAVA_OPTS% %GRADLE_OPTS% -Dorg.gradle.wrapper.properties="%WRAPPER_PROPERTIES%"
|
||||
|
||||
"%JAVA_EXE%" %GRADLE_OPTS% -classpath "%CLASSPATH%" %STARTER_MAIN_CLASS% %CMD_LINE_ARGS%
|
||||
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
dependsOn(':elasticsearch')
|
||||
|
||||
usePlugin 'java'
|
||||
apply plugin: 'java'
|
||||
|
||||
archivesBaseName = "$rootProject.archivesBaseName-$project.archivesBaseName"
|
||||
|
||||
|
@ -20,7 +20,7 @@ dependencies {
|
|||
|
||||
test {
|
||||
useTestNG()
|
||||
options.suiteName = project.name
|
||||
options.listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
options.systemProperties = ["es.test.log.conf": System.getProperty("es.test.log.conf", "log4j-gradle.properties")]
|
||||
suiteName = project.name
|
||||
listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
systemProperties["es.test.log.conf"] = System.getProperty("es.test.log.conf", "log4j-gradle.properties")
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
dependsOn(':test-testng')
|
||||
|
||||
usePlugin 'java'
|
||||
usePlugin 'maven'
|
||||
apply plugin: 'java'
|
||||
apply plugin: 'maven'
|
||||
|
||||
archivesBaseName = "$project.archivesBaseName"
|
||||
|
||||
|
@ -63,9 +63,9 @@ dependencies {
|
|||
test {
|
||||
useTestNG()
|
||||
jmvArgs = ["-ea", "-Xmx1024m"]
|
||||
options.suiteName = project.name
|
||||
options.listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
options.systemProperties = ["es.test.log.conf": System.getProperty("es.test.log.conf", "log4j-gradle.properties")]
|
||||
suiteName = project.name
|
||||
listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
systemProperties["es.test.log.conf"] = System.getProperty("es.test.log.conf", "log4j-gradle.properties")
|
||||
}
|
||||
|
||||
configure(install.repositories.mavenInstaller) {
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
dependsOn(':elasticsearch')
|
||||
|
||||
usePlugin 'java'
|
||||
apply plugin: 'java'
|
||||
|
||||
archivesBaseName = "$rootProject.archivesBaseName-$project.archivesBaseName"
|
||||
|
||||
|
@ -22,10 +22,8 @@ dependencies {
|
|||
test {
|
||||
useTestNG()
|
||||
jmvArgs = ["-ea", "-Xmx1024m"]
|
||||
options.suiteName = project.name
|
||||
options.listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
options.systemProperties = [
|
||||
"es.test.log.conf": System.getProperty("es.test.log.conf", "log4j-gradle.properties"),
|
||||
"java.net.preferIPv4Stack": "true"
|
||||
]
|
||||
suiteName = project.name
|
||||
listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
systemProperties["es.test.log.conf"] = System.getProperty("es.test.log.conf", "log4j-gradle.properties")
|
||||
systemProperties["java.net.preferIPv4Stack"] = "true"
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
usePlugin 'java'
|
||||
apply plugin: 'java'
|
||||
|
||||
archivesBaseName = "$rootProject.archivesBaseName-$project.archivesBaseName"
|
||||
|
||||
|
@ -18,5 +18,5 @@ dependencies {
|
|||
|
||||
test {
|
||||
useTestNG()
|
||||
options.systemProperties = ["es.test.log.conf": "log4j-gradle.properties"]
|
||||
systemProperties['es.test.log.conf'] = 'log4j-gradle.properties'
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
dependsOn(':elasticsearch')
|
||||
|
||||
usePlugin 'java'
|
||||
apply plugin: 'java'
|
||||
|
||||
archivesBaseName = "elasticsearch-attachments"
|
||||
|
||||
|
@ -43,11 +43,9 @@ dependencies {
|
|||
test {
|
||||
useTestNG()
|
||||
jmvArgs = ["-ea", "-Xmx1024m"]
|
||||
options.suiteName = project.name
|
||||
options.listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
options.systemProperties = [
|
||||
"es.test.log.conf": System.getProperty("es.test.log.conf", "log4j-gradle.properties")
|
||||
]
|
||||
suiteName = project.name
|
||||
listeners = ["org.elasticsearch.util.testng.Listeners"]
|
||||
systemProperties["es.test.log.conf"] = System.getProperty("es.test.log.conf", "log4j-gradle.properties")
|
||||
}
|
||||
|
||||
task explodedDist(dependsOn: [jar], description: 'Builds the plugin zip file') << {
|
||||
|
@ -67,17 +65,8 @@ task explodedDist(dependsOn: [jar], description: 'Builds the plugin zip file') <
|
|||
}
|
||||
}
|
||||
|
||||
task zip(type: Zip) {
|
||||
dependsOn explodedDist
|
||||
// classifier = 'all'
|
||||
}
|
||||
|
||||
zip.doFirst {task ->
|
||||
zipRootFolder = "" // its the plugin, don't create it under a specific name
|
||||
task.configure {
|
||||
zipFileSet(dir: explodedDistDir, prefix: zipRootFolder) {
|
||||
// just copy over everything
|
||||
}
|
||||
task zip(type: Zip, dependsOn: ['explodedDist']) {
|
||||
from(explodedDistDir) {
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue