Skip to content

Commit

Permalink
Merge branch 'trunk' of /Users/wzieba/LoginFlowFork into login_flow_r…
Browse files Browse the repository at this point in the history
…aw_history
  • Loading branch information
wzieba committed Sep 27, 2024
2 parents 4d46638 + 946482e commit 7f64fe0
Show file tree
Hide file tree
Showing 85 changed files with 8,915 additions and 0 deletions.
123 changes: 123 additions & 0 deletions WordPressLoginFlow/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,123 @@
plugins {
id "com.android.library"
id "org.jetbrains.kotlin.android"
id "org.jetbrains.kotlin.kapt"
id "com.automattic.android.publish-to-s3"
}

repositories {
maven {
url "https://a8c-libs.s3.amazonaws.com/android"
content {
includeGroup "org.wordpress"
includeGroup "org.wordpress.fluxc"
includeGroup "org.wordpress.wellsql"
includeGroup "com.gravatar"
}
}
mavenCentral()
google()
jcenter()
maven { url "https://www.jitpack.io" }
}

android {
compileOptions {
sourceCompatibility JavaVersion.VERSION_17
targetCompatibility JavaVersion.VERSION_17
}

kotlin {
jvmToolchain(17)
}

namespace "org.wordpress.android.login"

compileSdkVersion rootProject.compileSdkVersion

defaultConfig {
minSdkVersion rootProject.minSdkVersion
targetSdkVersion rootProject.targetSdkVersion
}
buildFeatures {
buildConfig true
}
}

dependencies {
implementation ("org.wordpress:utils:$wordpressUtilsVersion") {
exclude group: "com.android.volley"
}
implementation ("com.gravatar:gravatar:$gravatarSdkVersion")

implementation "androidx.appcompat:appcompat:$androidxAppCompatVersion"

implementation "androidx.constraintlayout:constraintlayout:$androidxConstraintLayoutVersion"
implementation "com.google.android.material:material:$materialVersion"

implementation "androidx.core:core:$androidxCoreVersion"

api "com.google.android.gms:play-services-auth:$playServicesAuthVersion"

implementation("org.wordpress:fluxc:$wordpressFluxCVersion") {
exclude group: "com.android.support"
exclude group: "org.wordpress", module: "utils"
}

implementation "com.github.bumptech.glide:glide:$glideVersion"
kapt "com.github.bumptech.glide:compiler:$glideVersion"

implementation "androidx.credentials:credentials:$credentialManagerVersion"
implementation "androidx.credentials:credentials-play-services-auth:$credentialManagerVersion"

// Dagger
implementation "com.google.dagger:dagger:$daggerVersion"
kapt "com.google.dagger:dagger-compiler:$daggerVersion"
compileOnly "org.glassfish:javax.annotation:$javaxAnnotationVersion"
implementation "com.google.dagger:dagger-android-support:$daggerVersion"
kapt "com.google.dagger:dagger-android-processor:$daggerVersion"

lintChecks "org.wordpress:lint:$wordpressLintVersion"

testImplementation "junit:junit:$junitVersion"
testImplementation "org.mockito:mockito-core:$mockitoVersion"
testImplementation "androidx.arch.core:core-testing:$androidxArchCoreVersion"
testImplementation "org.robolectric:robolectric:$robolectricVersion"
testImplementation "org.assertj:assertj-core:$assertjVersion"
}

// Add properties named "wp.xxx" to our BuildConfig
android.buildTypes.all { buildType ->
Properties gradleProperties = new Properties()
File propertiesFile = file("../gradle.properties")
if (propertiesFile.exists()) {
gradleProperties.load(new FileInputStream(propertiesFile))
} else {
// Load defaults
gradleProperties.load(new FileInputStream(file("../gradle.properties-example")))
}
gradleProperties.any { property ->
if (property.key.toLowerCase().startsWith("wp.")) {
buildType.buildConfigField "String", property.key.replace("wp.", "").replace(".", "_").toUpperCase(),
"\"${property.value}\""
}
if (property.key.toLowerCase().startsWith("wp.res.")) {
buildType.resValue "string", property.key.replace("wp.res.", "").replace(".", "_").toLowerCase(),
"${property.value}"
}
}
}

project.afterEvaluate {
publishing {
publications {
LoginPublication(MavenPublication) {
from components.release

groupId "org.wordpress"
artifactId "login"
// version is set by 'publish-to-s3' plugin
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
package org.wordpress.android.login

data class AuthOptions(
val isPasswordless: Boolean,
val isEmailVerified: Boolean
)
Loading

0 comments on commit 7f64fe0

Please sign in to comment.