Skip to content

Commit cf75fd6

Browse files
committed
new Gradle build
1 parent 9b8777a commit cf75fd6

8 files changed

+318
-0
lines changed

appengine/build.gradle

+17
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
repositories {
2+
mavenRepo urls:'http://maven-gae-plugin.googlecode.com/svn/repository/'
3+
}
4+
dependencies {
5+
compile project(":core")
6+
compile "com.google.appengine:appengine-api-1.0-sdk:1.3.4"
7+
compile "com.google.appengine:appengine-api-stubs:1.3.4"
8+
}
9+
10+
jar.appendix = 'gae'
11+
sourceSets {
12+
main {
13+
java {
14+
srcDir 'src'
15+
}
16+
}
17+
}

build.gradle

+15
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
subprojects {
2+
apply id: 'java'
3+
apply id: 'eclipse'
4+
5+
repositories {
6+
mavenCentral()
7+
}
8+
9+
dependencies {
10+
testCompile 'junit:junit:4.7'
11+
}
12+
13+
version = '0.1'
14+
archivesBaseName = 'grails-nosql'
15+
}

core/build.gradle

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
jar.appendix = 'gae'
2+
sourceSets {
3+
main {
4+
java {
5+
srcDir 'src'
6+
}
7+
}
8+
}

gradle/wrapper/gradle-wrapper.jar

10.5 KB
Binary file not shown.
+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#Mon Jan 18 09:35:53 CET 2010
2+
distributionBase=GRADLE_USER_HOME
3+
distributionPath=wrapper/dists
4+
zipStoreBase=GRADLE_USER_HOME
5+
distributionVersion=0.9-20100118091626+0100
6+
zipStorePath=wrapper/dists
7+
urlRoot=http\://snapshots.dist.codehaus.org/gradle
8+
distributionName=gradle
9+
distributionClassifier=bin

gradlew

+142
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,142 @@
1+
#!/bin/bash
2+
3+
##############################################################################
4+
## ##
5+
## Gradle wrapper script for UN*X ##
6+
## ##
7+
##############################################################################
8+
9+
# Uncomment those lines to set JVM options. GRADLE_OPTS and JAVA_OPTS can be used together.
10+
GRADLE_OPTS="$GRADLE_OPTS -Xmx1024m"
11+
# JAVA_OPTS="$JAVA_OPTS -Xmx512"
12+
13+
GRADLE_APP_NAME=Gradle
14+
15+
warn ( ) {
16+
echo "${PROGNAME}: $*"
17+
}
18+
19+
die ( ) {
20+
warn "$*"
21+
exit 1
22+
}
23+
24+
25+
# OS specific support (must be 'true' or 'false').
26+
cygwin=false
27+
msys=false
28+
darwin=false
29+
case "`uname`" in
30+
CYGWIN* )
31+
cygwin=true
32+
;;
33+
Darwin* )
34+
darwin=true
35+
;;
36+
MINGW* )
37+
msys=true
38+
;;
39+
esac
40+
41+
# Attempt to set JAVA_HOME if it's not already set.
42+
if [ -z "$JAVA_HOME" ] ; then
43+
if $darwin ; then
44+
[ -z "$JAVA_HOME" -a -d "/Library/Java/Home" ] && export JAVA_HOME="/Library/Java/Home"
45+
[ -z "$JAVA_HOME" -a -d "/System/Library/Frameworks/JavaVM.framework/Home" ] && export JAVA_HOME="/System/Library/Frameworks/JavaVM.framework/Home"
46+
else
47+
javaExecutable="`which javac`"
48+
[ -z "$javaExecutable" -o "`expr \"$javaExecutable\" : '\([^ ]*\)'`" = "no" ] && die "JAVA_HOME not set and cannot find javac to deduce location, please set JAVA_HOME."
49+
# readlink(1) is not available as standard on Solaris 10.
50+
readLink=`which readlink`
51+
[ `expr "$readLink" : '\([^ ]*\)'` = "no" ] && die "JAVA_HOME not set and readlink not available, please set JAVA_HOME."
52+
javaExecutable="`readlink -f \"$javaExecutable\"`"
53+
javaHome="`dirname \"$javaExecutable\"`"
54+
javaHome=`expr "$javaHome" : '\(.*\)/bin'`
55+
export JAVA_HOME="$javaHome"
56+
fi
57+
fi
58+
59+
# For Cygwin, ensure paths are in UNIX format before anything is touched.
60+
if $cygwin ; then
61+
[ -n "$JAVACMD" ] && JAVACMD=`cygpath --unix "$JAVACMD"`
62+
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
63+
fi
64+
65+
STARTER_MAIN_CLASS=org.gradle.wrapper.GradleWrapperMain
66+
CLASSPATH=`dirname "$0"`/gradle/wrapper/gradle-wrapper.jar
67+
WRAPPER_PROPERTIES=`dirname "$0"`/gradle/wrapper/gradle-wrapper.properties
68+
# Determine the Java command to use to start the JVM.
69+
if [ -z "$JAVACMD" ] ; then
70+
if [ -n "$JAVA_HOME" ] ; then
71+
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
72+
# IBM's JDK on AIX uses strange locations for the executables
73+
JAVACMD="$JAVA_HOME/jre/sh/java"
74+
else
75+
JAVACMD="$JAVA_HOME/bin/java"
76+
fi
77+
else
78+
JAVACMD="java"
79+
fi
80+
fi
81+
if [ ! -x "$JAVACMD" ] ; then
82+
die "JAVA_HOME is not defined correctly, can not execute: $JAVACMD"
83+
fi
84+
if [ -z "$JAVA_HOME" ] ; then
85+
warn "JAVA_HOME environment variable is not set"
86+
fi
87+
88+
# For Darwin, add GRADLE_APP_NAME to the JAVA_OPTS as -Xdock:name
89+
if $darwin; then
90+
JAVA_OPTS="$JAVA_OPTS -Xdock:name=$GRADLE_APP_NAME"
91+
# we may also want to set -Xdock:image
92+
fi
93+
94+
# For Cygwin, switch paths to Windows format before running java
95+
if $cygwin ; then
96+
JAVA_HOME=`cygpath --path --mixed "$JAVA_HOME"`
97+
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
98+
99+
# We build the pattern for arguments to be converted via cygpath
100+
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
101+
SEP=""
102+
for dir in $ROOTDIRSRAW ; do
103+
ROOTDIRS="$ROOTDIRS$SEP$dir"
104+
SEP="|"
105+
done
106+
OURCYGPATTERN="(^($ROOTDIRS))"
107+
# Add a user-defined pattern to the cygpath arguments
108+
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
109+
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
110+
fi
111+
# Now convert the arguments - kludge to limit ourselves to /bin/sh
112+
i=0
113+
for arg in "$@" ; do
114+
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
115+
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
116+
117+
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
118+
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
119+
else
120+
eval `echo args$i`="\"$arg\""
121+
fi
122+
i=$((i+1))
123+
done
124+
case $i in
125+
(0) set -- ;;
126+
(1) set -- "$args0" ;;
127+
(2) set -- "$args0" "$args1" ;;
128+
(3) set -- "$args0" "$args1" "$args2" ;;
129+
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
130+
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
131+
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
132+
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
133+
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
134+
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
135+
esac
136+
fi
137+
138+
"$JAVACMD" $JAVA_OPTS $GRADLE_OPTS \
139+
-classpath "$CLASSPATH" \
140+
-Dorg.gradle.wrapper.properties="$WRAPPER_PROPERTIES" \
141+
$STARTER_MAIN_CLASS \
142+
"$@"

gradlew.bat

+126
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,126 @@
1+
@if "%DEBUG%" == "" @echo off
2+
@rem ##########################################################################
3+
@rem ##
4+
@rem Gradle startup script for Windows ##
5+
@rem ##
6+
@rem ##########################################################################
7+
8+
@rem
9+
@rem $Revision: 10602 $ $Date: 2008-01-25 02:49:54 +0100 (ven., 25 janv. 2008) $
10+
@rem
11+
12+
@rem Set local scope for the variables with windows NT shell
13+
if "%OS%"=="Windows_NT" setlocal
14+
15+
@rem Uncomment those lines to set JVM options. GRADLE_OPTS and JAVA_OPTS can be used together.
16+
@rem set GRADLE_OPTS=%GRADLE_OPTS% -Xmx512
17+
@rem set JAVA_OPTS=%JAVA_OPTS% -Xmx512
18+
19+
set DIRNAME=%~dp0
20+
if "%DIRNAME%" == "" set DIRNAME=.\
21+
22+
@rem Determine the command interpreter to execute the "CD" later
23+
set COMMAND_COM="cmd.exe"
24+
if exist "%SystemRoot%\system32\cmd.exe" set COMMAND_COM="%SystemRoot%\system32\cmd.exe"
25+
if exist "%SystemRoot%\command.com" set COMMAND_COM="%SystemRoot%\command.com"
26+
27+
@rem Use explicit find.exe to prevent cygwin and others find.exe from being used
28+
set FIND_EXE="find.exe"
29+
if exist "%SystemRoot%\system32\find.exe" set FIND_EXE="%SystemRoot%\system32\find.exe"
30+
if exist "%SystemRoot%\command\find.exe" set FIND_EXE="%SystemRoot%\command\find.exe"
31+
32+
:check_JAVA_HOME
33+
@rem Make sure we have a valid JAVA_HOME
34+
if not "%JAVA_HOME%" == "" goto have_JAVA_HOME
35+
36+
echo.
37+
echo ERROR: Environment variable JAVA_HOME has not been set.
38+
echo.
39+
echo Please set the JAVA_HOME variable in your environment to match the
40+
echo location of your Java installation.
41+
echo.
42+
goto end
43+
44+
:have_JAVA_HOME
45+
@rem Validate JAVA_HOME
46+
%COMMAND_COM% /C DIR "%JAVA_HOME%" 2>&1 | %FIND_EXE% /I /C "%JAVA_HOME%" >nul
47+
if not errorlevel 1 goto init
48+
49+
echo.
50+
echo ERROR: JAVA_HOME might be set to an invalid directory: %JAVA_HOME%
51+
echo.
52+
echo Please set the JAVA_HOME variable in your environment to match the
53+
echo location of your Java installation if there are problems.
54+
echo.
55+
56+
:init
57+
@rem get name of script to launch with full path
58+
@rem Get command-line arguments, handling Windowz variants
59+
SET _marker=%JAVA_HOME: =%
60+
@rem IF NOT "%_marker%" == "%JAVA_HOME%" ECHO JAVA_HOME "%JAVA_HOME%" contains spaces. Please change to a location without spaces if this causes problems.
61+
62+
if not "%OS%" == "Windows_NT" goto win9xME_args
63+
if "%eval[2+2]" == "4" goto 4NT_args
64+
65+
IF "%_marker%" == "%JAVA_HOME%" goto :win9xME_args
66+
67+
set _FIXPATH=
68+
call :fixpath "%JAVA_HOME%"
69+
set JAVA_HOME=%_FIXPATH:~1%
70+
71+
goto win9xME_args
72+
73+
:fixpath
74+
if not %1.==. (
75+
for /f "tokens=1* delims=;" %%a in (%1) do (
76+
call :shortfilename "%%a" & call :fixpath "%%b"
77+
)
78+
)
79+
goto :EOF
80+
:shortfilename
81+
for %%i in (%1) do set _FIXPATH=%_FIXPATH%;%%~fsi
82+
goto :EOF
83+
84+
85+
:win9xME_args
86+
@rem Slurp the command line arguments.
87+
set CMD_LINE_ARGS=
88+
set _SKIP=2
89+
90+
:win9xME_args_slurp
91+
if "x%~1" == "x" goto execute
92+
93+
set CMD_LINE_ARGS=%*
94+
goto execute
95+
96+
:4NT_args
97+
@rem Get arguments from the 4NT Shell from JP Software
98+
set CMD_LINE_ARGS=%$
99+
100+
:execute
101+
@rem Setup the command line
102+
103+
set STARTER_MAIN_CLASS=org.gradle.wrapper.GradleWrapperMain
104+
set CLASSPATH=%DIRNAME%\gradle\wrapper\gradle-wrapper.jar
105+
set WRAPPER_PROPERTIES=%DIRNAME%\gradle\wrapper\gradle-wrapper.properties
106+
set JAVA_EXE=%JAVA_HOME%\bin\java.exe
107+
108+
set GRADLE_OPTS=%JAVA_OPTS% %GRADLE_OPTS% -Dorg.gradle.wrapper.properties="%WRAPPER_PROPERTIES%"
109+
110+
"%JAVA_EXE%" %GRADLE_OPTS% -classpath "%CLASSPATH%" %STARTER_MAIN_CLASS% %CMD_LINE_ARGS%
111+
112+
:end
113+
@rem End local scope for the variables with windows NT shell
114+
if "%ERRORLEVEL%"=="0" goto mainEnd
115+
116+
if not "%OS%"=="Windows_NT" echo 1 > nul | choice /n /c:1
117+
118+
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
119+
rem the _cmd.exe /c_ return code!
120+
if not "" == "%GRADLE_EXIT_CONSOLE%" exit "%ERRORLEVEL%"
121+
exit /b "%ERRORLEVEL%"
122+
123+
:mainEnd
124+
if "%OS%"=="Windows_NT" endlocal
125+
126+
:omega

settings.gradle

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
include "core", "appengine"

0 commit comments

Comments
 (0)