Skip to content

Commit

Permalink
WIP migrating to newer gradle and version catalog
Browse files Browse the repository at this point in the history
  • Loading branch information
lalwani committed Feb 20, 2024
1 parent be2efd4 commit 3fbbf22
Show file tree
Hide file tree
Showing 11 changed files with 70 additions and 187 deletions.
25 changes: 16 additions & 9 deletions build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
/*
* Copyright (C) 2024. Uber Technologies
*
* 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.
*/

import com.android.build.api.dsl.ApplicationExtension
import com.android.build.api.dsl.CommonExtension
import com.android.build.api.variant.ApplicationAndroidComponentsExtension
Expand Down Expand Up @@ -83,15 +99,6 @@ subprojects {
externalDocumentationLink {
url.set(URI("https://kotlin.github.io/kotlinx.coroutines/index.html").toURL())
}
perPackageOption {
// language=RegExp
matchingRegex.set(".*\\.internal\\..*")
suppress.set(true)
}
val moduleMd = project.layout.projectDirectory.file("Module.md")
if (moduleMd.asFile.exists()) {
includes.from(moduleMd)
}
}
}

Expand Down
2 changes: 1 addition & 1 deletion core-android/build.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*
* Copyright (C) 2017. Uber Technologies
* Copyright (C) 2024. Uber Technologies
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
GROUP=com.uber.sdk

#Version is managed by Gradle Release Plugin
version=0.10.11
VERSION_NAME=0.10.11
version=0.10.11-SNAPSHOT
VERSION_NAME=0.10.11-SNAPSHOT
POM_URL=https\://developer.uber.com

POM_SCM_URL=https\://github.com/uber/rides-android-sdk/
Expand Down
12 changes: 5 additions & 7 deletions gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,21 @@

[versions]
agp = "8.0.2"
androidTest = "0.5"
androidxVersion = "1.0.0"
uberJava = "0.8.5"
gradleVersion = "8.2.1"
buildToolsVersion = "28.0.2"
mavenPublish = "0.27.0"
kotlin = "1.9.22"
junit = "4.13.2"
runner = "1.0.2"
espresso-core = "3.0.2"
appcompat-v7 = "28.0.0"
compileSdkVersion = "33"
compileSdkVersion = "34"
minSdkVersion = "26"
targetSdkVersion = "33"
targetSdkVersion = "34"
jvmTarget = "1.8"
dokka = "1.9.10"
jsr305 = "3.0.2"
retrofit = "2.9.0"

[plugins]
android-application = { id = "com.android.application", version.ref = "agp" }
Expand All @@ -32,8 +30,6 @@ jsr305 = { module = "com.google.code.findbugs:jsr305", version.ref = "jsr305" }
annotations = { module ="androidx.annotation:annotation", version.ref="androidxVersion"}
appCompat = { module ="androidx.appcompat:appcompat", version.ref="androidxVersion"}
chrometabs = { module = "androidx.browser:browser" , version.ref = "androidxVersion"}
androidRunner = { module="com.android.support.test:runner", version.ref = "androidTest"}
androidRules = { module="com.android.support.test:rules", version.ref = "androidTest"}
junit = "junit:junit:4.13.2"
robolectric = "org.robolectric:robolectric:4.11.1"
assertj = "org.assertj:assertj-core:3.25.1"
Expand All @@ -46,3 +42,5 @@ junit-junit = { group = "junit", name = "junit", version.ref = "junit" }
runner = { group = "com.android.support.test", name = "runner", version.ref = "runner" }
espresso-core = { group = "com.android.support.test.espresso", name = "espresso-core", version.ref = "espresso-core" }
appcompat-v7 = { group = "com.android.support", name = "appcompat-v7", version.ref = "appcompat-v7" }
retrofit = { module = "com.squareup.retrofit2:retrofit", version.ref = "retrofit"}
retrofit-moshi = { module = "com.squareup.retrofit2:converter-moshi", version.ref = "retrofit"}
70 changes: 0 additions & 70 deletions samples/login-with-auth-code-demo/build.gradle

This file was deleted.

2 changes: 1 addition & 1 deletion samples/login-with-auth-code-demo/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ android {
dependencies {
implementation(libs.appCompat)
implementation(libs.retrofit)
implementation(libs.moshi.retrofit)
implementation(libs.retrofit.moshi)
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,8 @@
android:icon="@drawable/uber_sample_ic_launcher">
<activity
android:name="com.uber.sdk.android.samples.DemoActivity"
android:label="@string/app_name">
android:label="@string/app_name"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

Expand Down
70 changes: 0 additions & 70 deletions samples/request-button-sample/build.gradle

This file was deleted.

3 changes: 2 additions & 1 deletion samples/request-button-sample/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
android:icon="@drawable/uber_sample_ic_launcher">
<activity
android:name=".SampleActivity"
android:label="@string/app_name">
android:label="@string/app_name"
android:exported="true">
<intent-filter>
<action android:name="android.intent.action.MAIN" />

Expand Down
25 changes: 0 additions & 25 deletions settings.gradle

This file was deleted.

41 changes: 41 additions & 0 deletions settings.gradle.kts
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
/*
* Copyright (C) 2024. Uber Technologies
*
* 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.
*/

pluginManagement {
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
}

dependencyResolutionManagement {
repositories {
google()
mavenCentral()
gradlePluginPortal()
}
}

rootProject.name = "uber-android-sdk"

include(
":core-android",
":rides-android",
":samples:request-button-sample",
":samples:login-sample",
":samples:login-with-auth-code-demo",
)

0 comments on commit 3fbbf22

Please sign in to comment.