Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix local & CI builds #431

Merged
merged 11 commits into from
May 24, 2021
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ jobs:
run: chmod +x gradlew
- name: Run unit tests with Gradle
run: ./gradlew :opensrp-chw-core:jacocoTestReport --stacktrace
env:
GPR_USER: ${{ github.actor }}
GPR_API_KEY: ${{ secrets.GITHUB_TOKEN }}
- name: Generate Javadoc with Gradle
run: ./gradlew javadoc
- name: Upload coverage to Coveralls with Gradle
Expand Down
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
*.iml
.gradle
/local.properties
/github.properties
/captures
*.ipr
*.iws
Expand Down
8 changes: 2 additions & 6 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ buildscript {
maven { url 'https://jitpack.io' }
maven { url "https://repo.maven.apache.org/maven2" }
maven { url "http://cloudant.github.io/cloudant-sync-eap/repository" }
maven { url "http://dl.bintray.com/ona/kujaku" }
maven{ url "https://plugins.gradle.org/m2/" }
mavenLocal()
}
Expand Down Expand Up @@ -42,7 +41,6 @@ allprojects {

repositories {
google()
jcenter()
mavenLocal()
mavenCentral()
maven { url 'https://maven.google.com' }
Expand All @@ -54,10 +52,8 @@ allprojects {
maven { url 'https://maven.fabric.io/public' }
maven { url "https://s3.amazonaws.com/repo.commonsware.com" }
maven { url "https://s3.amazonaws.com/repo.commonsware.com" }
maven { url "https://dl.bintray.com/ona/rdt-capture" }
maven { url "http://dl.bintray.com/ona/kujaku" }
maven { url 'https://dl.bintray.com/ibm-watson-health/ibm-fhir-server-releases'}
maven{ url "https://plugins.gradle.org/m2/" }
jcenter()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need JCenter here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, we don't. I've removed the entry

}
}

Expand All @@ -68,10 +64,10 @@ configure(allprojects) { project ->
buildscript {
repositories {
google()
jcenter()
mavenCentral()
mavenLocal()
maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }
jcenter()
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we still need JCenter here?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, we don't. I've removed the entry

}
}
}
Expand Down
27 changes: 24 additions & 3 deletions opensrp-chw-core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,18 @@ allprojects {
repositories {
maven { url 'https://oss.sonatype.org/content/repositories/snapshots/' }
maven { url "https://s3.amazonaws.com/repo.commonsware.com" }
maven {
def githubProperties = new Properties()
if (project.rootProject.file("github.properties").exists()) {
githubProperties.load(new FileInputStream(rootProject.file("github.properties")))
}
name = "GitHubPackages"
url = uri("https://maven.pkg.github.com/onaio/kujaku")
credentials {
username = githubProperties['gpr.usr'] ?: System.getenv("GPR_USER")
password = githubProperties['gpr.key'] ?: System.getenv("GPR_API_KEY")
}
}
mavenLocal()
}
}
Expand Down Expand Up @@ -107,7 +119,7 @@ dependencies {
//implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.multidex:multidex:2.0.1'
implementation 'com.mapbox.mapboxsdk:mapbox-sdk-turf:5.1.0'
implementation('io.ona.kujaku:library:0.8.9') {
implementation('io.ona.kujaku:library:0.9.0') {
exclude group: 'com.android.volley', module: 'volley'
exclude group: 'stax', module: 'stax-api'
}
Expand Down Expand Up @@ -139,9 +151,9 @@ dependencies {
exclude group: 'com.google.guava', module: 'guava'
}

compileOnly 'com.ibm.fhir:fhir-model:4.2.3'
compileOnly 'com.ibm.fhir:fhir-model:4.7.0'

api('org.smartregister:opensrp-client-core:4.2.16-SNAPSHOT@aar') {
api('org.smartregister:opensrp-client-core:4.3.3-SNAPSHOT@aar') {
transitive = true
exclude group: 'com.github.bmelnychuk', module: 'atv'
exclude group: 'com.google.guava', module: 'guava'
Expand All @@ -166,6 +178,7 @@ dependencies {
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'com.android.support', module: 'appcompat-v7'
exclude group: 'id.zelory', module: 'compressor'
}

api('org.smartregister:opensrp-client-immunization:3.0.3-SNAPSHOT@aar') {
Expand All @@ -182,6 +195,7 @@ dependencies {
exclude group: 'com.android.support', module: 'support-v4'
exclude group: 'com.android.support', module: 'design'
exclude group: 'com.github.lecho', module: 'hellocharts-library'
exclude group: 'id.zelory', module: 'compressor'
}

api('org.smartregister:opensrp-client-growth-monitoring:1.1.23-SNAPSHOT@aar') {
Expand All @@ -201,6 +215,7 @@ dependencies {
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'org.smartregister', module: 'opensrp-client-immunization'
exclude group: 'org.smartregister', module: 'opensrp-client-family'
exclude group: 'id.zelory', module: 'compressor'
}

api('org.smartregister:opensrp-client-chw-pnc:2.0.0-SNAPSHOT@aar') {
Expand All @@ -212,6 +227,7 @@ dependencies {
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'org.smartregister', module: 'opensrp-client-immunization'
exclude group: 'org.smartregister', module: 'opensrp-client-family'
exclude group: 'id.zelory', module: 'compressor'
}

api('org.smartregister:opensrp-client-chw-malaria:1.2.19-SNAPSHOT@aar') {
Expand All @@ -220,6 +236,7 @@ dependencies {
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'com.android.support', module: 'appcompat-v7'
exclude group: 'id.zelory', module: 'compressor'
}

api('org.smartregister:opensrp-chw-family-planning:1.0.27-SNAPSHOT@aar') {
Expand All @@ -228,13 +245,15 @@ dependencies {
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'com.android.support', module: 'appcompat-v7'
exclude group: 'id.zelory', module: 'compressor'
}
api('org.smartregister:opensrp-client-chw-referral:1.3.6-SNAPSHOT@aar') {
transitive = true
exclude group: 'org.smartregister', module: 'opensrp-client-core'
exclude group: 'org.smartregister', module: 'opensrp-client-native-form'
exclude group: 'org.smartregister', module: 'opensrp-client-configurable-views'
exclude group: 'com.android.support', module: 'appcompat-v7'
exclude group: 'id.zelory', module: 'compressor'
}

api('org.smartregister:opensrp-client-opd:0.0.13-SNAPSHOT@aar') {
Expand All @@ -247,6 +266,8 @@ dependencies {
exclude group: 'id.zelory', module: 'compressor'
}

implementation "id.zelory:compressor:2.1.1"

api 'com.google.guava:guava:20.0'
api 'io.reactivex.rxjava2:rxandroid:2.1.1'
// Because RxAndroid releases are few and far between, it is recommended you also
Expand Down