Skip to content

Commit

Permalink
Update the build.gradle (#306)
Browse files Browse the repository at this point in the history
1. More comments to build.gradle
2. add the wrapper jars
3. tags
  • Loading branch information
lesv authored Aug 18, 2016
1 parent b54ad45 commit 31f9f1c
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 26 deletions.
61 changes: 36 additions & 25 deletions appengine/helloworld-new-plugins/build.gradle
Original file line number Diff line number Diff line change
@@ -1,53 +1,64 @@
buildscript {
// Copyright 2015 Google Inc. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
// [start gradle]
buildscript { // Configuration for building
repositories {
jcenter() // Bintray's repository - a fast Maven Central mirror & more
jcenter() // Bintray's repository - a fast Maven Central mirror & more
mavenCentral()
}
dependencies {
classpath 'com.google.cloud.tools:appengine-gradle-plugin:+' // latest App Engine Gradle plugin
classpath 'com.google.cloud.tools:appengine-gradle-plugin:+' // latest App Engine Gradle tasks
}
}

repositories {
repositories { // repositories for Jar's you access in your code
maven {
url 'https://maven-central.storage.googleapis.com' // Google's mirror of Maven Central
// url 'https://oss.sonatype.org/content/repositories/snapshots' // SNAPSHOT Reposiotry (if needed)
url 'https://maven-central.storage.googleapis.com' // Google's mirror of Maven Central
// url 'https://oss.sonatype.org/content/repositories/snapshots' // SNAPSHOT Reposiotry (if needed)
}
jcenter()
mavenCentral()
}

apply plugin: 'java'
apply plugin: 'war'
apply plugin: 'com.google.cloud.tools.appengine'
apply plugin: 'java' // standard Java tasks
apply plugin: 'war' // standard Web Archive plugin
apply plugin: 'com.google.cloud.tools.appengine' // App Engine tasks

dependencies { // Servlet for App Engine Standard -- only one of these need to be uncommented.
// providedCompile group: 'javax.servlet', name: 'servlet-api', version:'2.5'
providedCompile 'javax.servlet:javax.servlet-api:3.1.0' // if beta-quickstart in appengine-web.xml
providedCompile 'javax.servlet:javax.servlet-api:3.1.0' // if java_quickstart in appengine-web.xml
compile 'com.google.appengine:appengine:+
// Add your dependencies here.
}
task wrapper(type: Wrapper) { // use the gradle wrapper "./gradlew.sh ..."
gradleVersion = '2.14' // "gradle wrapper --gradle-version 2.14" (to create files and directories)
}
model {
appengine {
run { // dev appserver configuration (standard environments only)
jvmFlags = ['-Dappengine.user.timezone=UTC']
host = '127.0.0.1'
port = 8080
appengine { // App Engine tasks configuration
run { // local (dev_appserver) configuration (standard environments only)
port = 8080 // default
}
deploy { // deploy configuration
promote = true
stopPreviousVersion = true
deploy { // deploy configuration
stopPreviousVersion = true // default - stop the current version
promote = true // default - & make this the current version
}
}
}
group = 'com.example.appengine'
version = '1.0-SNAPSHOT'
group = 'com.example.appengine' // Generated output GroupId
version = '1.0-SNAPSHOT' // Version in generated output
sourceCompatibility = JavaVersion.VERSION_1_7
targetCompatibility = JavaVersion.VERSION_1_7
sourceCompatibility = JavaVersion.VERSION_1_7 // App Engine Standard uses Java 7
targetCompatibility = JavaVersion.VERSION_1_7 // App Engine Standard uses Java 7
// [end gradle]
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#Thu Aug 04 16:12:44 PDT 2016
#Wed Aug 17 16:32:26 PDT 2016
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
Expand Down

0 comments on commit 31f9f1c

Please sign in to comment.