mirror of
https://github.com/fork-maintainers/iceraven-browser
synced 2024-11-09 19:10:42 +00:00
Move architecture/mvi code to separate gradle module.
This commit is contained in:
parent
27a56e2974
commit
344bc0aea6
@ -89,7 +89,8 @@ androidExtensions {
|
|||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
implementation fileTree(dir: 'libs', include: ['*.jar'])
|
implementation project(':architecture')
|
||||||
|
|
||||||
implementation Deps.kotlin_stdlib
|
implementation Deps.kotlin_stdlib
|
||||||
implementation Deps.androidx_appcompat
|
implementation Deps.androidx_appcompat
|
||||||
implementation Deps.androidx_constraintlayout
|
implementation Deps.androidx_constraintlayout
|
||||||
|
40
architecture/build.gradle
Normal file
40
architecture/build.gradle
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
|
apply plugin: 'com.android.library'
|
||||||
|
apply plugin: 'kotlin-android'
|
||||||
|
apply plugin: 'kotlin-android-extensions'
|
||||||
|
|
||||||
|
android {
|
||||||
|
compileSdkVersion 28
|
||||||
|
|
||||||
|
defaultConfig {
|
||||||
|
minSdkVersion 21
|
||||||
|
targetSdkVersion 28
|
||||||
|
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
|
||||||
|
}
|
||||||
|
|
||||||
|
buildTypes {
|
||||||
|
release {
|
||||||
|
minifyEnabled false
|
||||||
|
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
androidExtensions {
|
||||||
|
experimental = true
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
implementation Deps.kotlin_stdlib
|
||||||
|
|
||||||
|
implementation Deps.androidx_annotation
|
||||||
|
implementation Deps.androidx_lifecycle_runtime
|
||||||
|
|
||||||
|
implementation Deps.mozilla_support_base
|
||||||
|
|
||||||
|
implementation Deps.rxAndroid
|
||||||
|
implementation Deps.rxKotlin
|
||||||
|
}
|
21
architecture/proguard-rules.pro
vendored
Normal file
21
architecture/proguard-rules.pro
vendored
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
# Add project specific ProGuard rules here.
|
||||||
|
# You can control the set of applied configuration files using the
|
||||||
|
# proguardFiles setting in build.gradle.
|
||||||
|
#
|
||||||
|
# For more details, see
|
||||||
|
# http://developer.android.com/guide/developing/tools/proguard.html
|
||||||
|
|
||||||
|
# If your project uses WebView with JS, uncomment the following
|
||||||
|
# and specify the fully qualified class name to the JavaScript interface
|
||||||
|
# class:
|
||||||
|
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
|
||||||
|
# public *;
|
||||||
|
#}
|
||||||
|
|
||||||
|
# Uncomment this to preserve the line number information for
|
||||||
|
# debugging stack traces.
|
||||||
|
#-keepattributes SourceFile,LineNumberTable
|
||||||
|
|
||||||
|
# If you keep the line number information, uncomment this to
|
||||||
|
# hide the original source file name.
|
||||||
|
#-renamesourcefileattribute SourceFile
|
5
architecture/src/main/AndroidManifest.xml
Normal file
5
architecture/src/main/AndroidManifest.xml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<!-- This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
|
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
|
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
||||||
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
|
package="org.mozilla.fenix.mvi"/>
|
@ -7,7 +7,6 @@ package org.mozilla.fenix.mvi
|
|||||||
import io.reactivex.ObservableTransformer
|
import io.reactivex.ObservableTransformer
|
||||||
import io.reactivex.subjects.Subject
|
import io.reactivex.subjects.Subject
|
||||||
import mozilla.components.support.base.log.logger.Logger
|
import mozilla.components.support.base.log.logger.Logger
|
||||||
import org.mozilla.fenix.BuildConfig
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* An action is a command or intent the user performed
|
* An action is a command or intent the user performed
|
@ -38,7 +38,7 @@ task clean(type: Delete) {
|
|||||||
detekt {
|
detekt {
|
||||||
// The version number is duplicated, please refer to plugins block for more details
|
// The version number is duplicated, please refer to plugins block for more details
|
||||||
version = "1.0.0.RC9.2"
|
version = "1.0.0.RC9.2"
|
||||||
input = files("$projectDir/app")
|
input = files("$projectDir/app", "$projectDir/architecture")
|
||||||
config = files("$projectDir/config/detekt.yml")
|
config = files("$projectDir/config/detekt.yml")
|
||||||
filters = ".*test.*,.*/resources/.*,.*/tmp/.*"
|
filters = ".*test.*,.*/resources/.*,.*/tmp/.*"
|
||||||
|
|
||||||
@ -62,5 +62,5 @@ task ktlint(type: JavaExec, group: "verification") {
|
|||||||
description = "Check Kotlin code style."
|
description = "Check Kotlin code style."
|
||||||
classpath = configurations.ktlint
|
classpath = configurations.ktlint
|
||||||
main = "com.github.shyiko.ktlint.Main"
|
main = "com.github.shyiko.ktlint.Main"
|
||||||
args "app/**/*.kt"
|
args "app/**/*.kt", "architecture/**/*.kt"
|
||||||
}
|
}
|
@ -14,6 +14,9 @@ private object Versions {
|
|||||||
const val androidx_appcompat = "1.0.2"
|
const val androidx_appcompat = "1.0.2"
|
||||||
const val androidx_constraint_layout = "2.0.0-alpha3"
|
const val androidx_constraint_layout = "2.0.0-alpha3"
|
||||||
const val androidx_preference = "1.1.0-alpha02"
|
const val androidx_preference = "1.1.0-alpha02"
|
||||||
|
const val androidx_legacy = "1.0.0"
|
||||||
|
const val androidx_annotation = "1.0.1"
|
||||||
|
const val androidx_lifecycle = "2.0.0"
|
||||||
|
|
||||||
const val mozilla_android_components = "0.41.0-SNAPSHOT"
|
const val mozilla_android_components = "0.41.0-SNAPSHOT"
|
||||||
|
|
||||||
@ -21,7 +24,6 @@ private object Versions {
|
|||||||
const val test_tools = "1.0.2"
|
const val test_tools = "1.0.2"
|
||||||
const val espresso_core = "2.2.2"
|
const val espresso_core = "2.2.2"
|
||||||
|
|
||||||
const val androidx_legacy = "1.0.0"
|
|
||||||
const val android_arch_navigation = "1.0.0-alpha11"
|
const val android_arch_navigation = "1.0.0-alpha11"
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -42,9 +44,6 @@ object Deps {
|
|||||||
const val geckoview_nightly_arm = "org.mozilla.geckoview:geckoview-nightly-armeabi-v7a:${Versions.geckoNightly}"
|
const val geckoview_nightly_arm = "org.mozilla.geckoview:geckoview-nightly-armeabi-v7a:${Versions.geckoNightly}"
|
||||||
const val geckoview_nightly_x86 = "org.mozilla.geckoview:geckoview-nightly-x86:${Versions.geckoNightly}"
|
const val geckoview_nightly_x86 = "org.mozilla.geckoview:geckoview-nightly-x86:${Versions.geckoNightly}"
|
||||||
|
|
||||||
const val androidx_appcompat = "androidx.appcompat:appcompat:${Versions.androidx_appcompat}"
|
|
||||||
const val androidx_constraintlayout = "androidx.constraintlayout:constraintlayout:${Versions.androidx_constraint_layout}"
|
|
||||||
|
|
||||||
const val mozilla_concept_engine = "org.mozilla.components:concept-engine:${Versions.mozilla_android_components}"
|
const val mozilla_concept_engine = "org.mozilla.components:concept-engine:${Versions.mozilla_android_components}"
|
||||||
const val mozilla_concept_tabstray = "org.mozilla.components:concept-tabstray:${Versions.mozilla_android_components}"
|
const val mozilla_concept_tabstray = "org.mozilla.components:concept-tabstray:${Versions.mozilla_android_components}"
|
||||||
const val mozilla_concept_toolbar = "org.mozilla.components:concept-toolbar:${Versions.mozilla_android_components}"
|
const val mozilla_concept_toolbar = "org.mozilla.components:concept-toolbar:${Versions.mozilla_android_components}"
|
||||||
@ -79,6 +78,7 @@ object Deps {
|
|||||||
|
|
||||||
const val mozilla_lib_crash = "org.mozilla.components:lib-crash:${Versions.mozilla_android_components}"
|
const val mozilla_lib_crash = "org.mozilla.components:lib-crash:${Versions.mozilla_android_components}"
|
||||||
|
|
||||||
|
const val mozilla_support_base = "org.mozilla.components:support-base:${Versions.mozilla_android_components}"
|
||||||
const val mozilla_support_ktx = "org.mozilla.components:support-ktx:${Versions.mozilla_android_components}"
|
const val mozilla_support_ktx = "org.mozilla.components:support-ktx:${Versions.mozilla_android_components}"
|
||||||
|
|
||||||
const val sentry = "io.sentry:sentry-android:${Versions.sentry}"
|
const val sentry = "io.sentry:sentry-android:${Versions.sentry}"
|
||||||
@ -87,8 +87,13 @@ object Deps {
|
|||||||
const val tools_test_runner = "com.android.support.test:runner:${Versions.test_tools}"
|
const val tools_test_runner = "com.android.support.test:runner:${Versions.test_tools}"
|
||||||
const val tools_espresso_core = "com.android.support.test.espresso:espresso-core:${Versions.espresso_core}"
|
const val tools_espresso_core = "com.android.support.test.espresso:espresso-core:${Versions.espresso_core}"
|
||||||
|
|
||||||
|
const val androidx_annotation = "androidx.annotation:annotation:${Versions.androidx_annotation}"
|
||||||
|
const val androidx_appcompat = "androidx.appcompat:appcompat:${Versions.androidx_appcompat}"
|
||||||
|
const val androidx_constraintlayout = "androidx.constraintlayout:constraintlayout:${Versions.androidx_constraint_layout}"
|
||||||
const val androidx_legacy = "androidx.legacy:legacy-support-v4:${Versions.androidx_legacy}"
|
const val androidx_legacy = "androidx.legacy:legacy-support-v4:${Versions.androidx_legacy}"
|
||||||
|
const val androidx_lifecycle_runtime = "androidx.lifecycle:lifecycle-runtime:${Versions.androidx_lifecycle}"
|
||||||
const val androidx_preference = "androidx.preference:preference-ktx:${Versions.androidx_preference}"
|
const val androidx_preference = "androidx.preference:preference-ktx:${Versions.androidx_preference}"
|
||||||
const val android_arch_navigation = "android.arch.navigation:navigation-fragment:${Versions.android_arch_navigation}"
|
const val android_arch_navigation = "android.arch.navigation:navigation-fragment:${Versions.android_arch_navigation}"
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1 +1 @@
|
|||||||
include ':app'
|
include ':app', ':architecture'
|
||||||
|
Loading…
Reference in New Issue
Block a user