Skip to content
This repository has been archived by the owner on Oct 11, 2024. It is now read-only.

Commit

Permalink
Compile generated services with latest java library version of mobile…
Browse files Browse the repository at this point in the history
…-sdk
  • Loading branch information
victorlaerte committed Aug 23, 2018
1 parent dbfadfe commit c25dd48
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 1 deletion.
1 change: 1 addition & 0 deletions android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
buildscript {
repositories {
google()
jcenter()
mavenCentral()
maven {
Expand Down
2 changes: 2 additions & 0 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,10 @@ ext {

allprojects {
repositories {
google()
mavenLocal()
mavenCentral()
jcenter()
}
}

Expand Down
11 changes: 10 additions & 1 deletion modules.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,12 @@ configure(subprojects.findAll { it.name.startsWith('modules/') }) {
}

dependencies {
compile project(path: ':liferay-android-sdk', configuration: 'default')
if (isJavaCompile()) {
compile 'com.liferay.mobile:liferay-android-sdk:7.0.9'
} else {
compile project(path: ':liferay-android-sdk', configuration: 'default')
}

compile group: 'com.google.android', name: 'android', version: '2.3.3'
compile group: 'org.apache.httpcomponents', name: 'httpclient-android', version: '4.3.3'
compile group: 'org.apache.httpcomponents', name: 'httpmime', version: '4.3.3'
Expand Down Expand Up @@ -129,6 +134,10 @@ createModule {
description = "Creates SDK Builder modules."
}

def isJavaCompile() {
return gradle.startParameter.taskNames.size() > 0 && gradle.startParameter.taskNames.get(0).equals("jar")
}

def addTextColor(text, startColor, endColor=COLORS.WHITE) {
return "${Character.toChars(27)}[${startColor}m${text}${Character.toChars(27)}[${endColor}m"
}
Expand Down

0 comments on commit c25dd48

Please sign in to comment.