All Projects → GitLqr → RePluginX

GitLqr / RePluginX

Licence: Apache-2.0 license
🔥 Supports AndroidX and Android-Support

Programming Languages

java
68154 projects - #9 most used programming language
groovy
2714 projects

Projects that are alternatives of or similar to RePluginX

bye-bye-jetifier
Gradle Plugin to verify if you can keep Android Jetifier disabled
Stars: ✭ 173 (+440.63%)
Mutual labels:  android-support, androidx
slush
This library will no longer be updated 😭
Stars: ✭ 26 (-18.75%)
Mutual labels:  androidx
Aesthetic
[DEPRECATED]
Stars: ✭ 2,044 (+6287.5%)
Mutual labels:  androidx
nice-animals
Simple android app that shows nice animals pictures
Stars: ✭ 15 (-53.12%)
Mutual labels:  androidx
Component
🔥🔥🔥A powerful componentized framework.一个强大、100% 兼容、支持 AndroidX、支持 Kotlin并且灵活的组件化框架
Stars: ✭ 2,434 (+7506.25%)
Mutual labels:  androidx
MyLogLibrary
🚧 - Simple Android Kotlin logger (2017/2020)
Stars: ✭ 31 (-3.12%)
Mutual labels:  androidx
Expansionpanel
Android - Expansion panels contain creation flows and allow lightweight editing of an element.
Stars: ✭ 1,984 (+6100%)
Mutual labels:  androidx
Melon
UNES, o aplicativo que cria notificações para as ações do Portal Sagres.
Stars: ✭ 41 (+28.13%)
Mutual labels:  androidx
ANE-AndroidSupport
Android Support Library Native Extension
Stars: ✭ 21 (-34.37%)
Mutual labels:  android-support
raffler-kotlin
A raffling app developed as a playground to study many topics related to Android. Kotlin + Coroutines + MVVM
Stars: ✭ 44 (+37.5%)
Mutual labels:  androidx
QuantityPickerView
A View capable of increasing or decreasing a unit value with a toggle animation
Stars: ✭ 42 (+31.25%)
Mutual labels:  androidx
DDLCModTemplate2.0
A new template for producing DDLC mods that adhere to Team Salvato's guidelines based off DDLC itself.
Stars: ✭ 22 (-31.25%)
Mutual labels:  android-support
Praxis
Example Android project using MVVM, DaggerAndroid, Jetpack Compose, Retrofit, Coroutines and Multi module architecture ✌🏽
Stars: ✭ 258 (+706.25%)
Mutual labels:  androidx
Bgaswipebacklayout Android
Android Activity 滑动返回。支持微信滑动返回样式、横屏滑动返回、全屏滑动返回
Stars: ✭ 2,251 (+6934.38%)
Mutual labels:  androidx
Clean-MVVM-NewsApp
Android News app developed using Clean + MVVM architecture
Stars: ✭ 52 (+62.5%)
Mutual labels:  androidx
Bgaphotopicker Android
Android 图片选择、预览、九宫格图片控件、拖拽排序九宫格图片控件
Stars: ✭ 2,131 (+6559.38%)
Mutual labels:  androidx
pixel
A lightweight image loader for Android backed by Kotlin Coroutines.
Stars: ✭ 79 (+146.88%)
Mutual labels:  androidx
Biometric-Authentication-Android
A sample implementation of AndroidX biometrics API using Kotlin. Authenticate using biometrics or PIN/Password if biometrics isn't available on device. Fully implemented in Jetpack compose using Material 3 dynamic theming and also has a separate implementation in xml with MDC 3.
Stars: ✭ 29 (-9.37%)
Mutual labels:  androidx
kotlin-coroutines-android
Useful extensions for coroutines. AutoDispose + MainScope
Stars: ✭ 84 (+162.5%)
Mutual labels:  android-support
mindorks-cct
A sample application demoing chrome custom tabs in kotlin in androidx 🎨
Stars: ✭ 27 (-15.62%)
Mutual labels:  androidx

RePluginX

RePluginX Logo

license

特性

  • 支持 AnroidSupport、AndroidX 工程
  • 支持 RePlugin Transform 开关 配置 (enable)
  • 支持 坑位 Activity 的屏幕方向 配置 (screenOrientation)
  • 支持 移除 class 文件 配置 (classExcludesclassIncludes)
  • 支持 多版本 AGP 2.x 3.x 4.x (7.x 暂未兼容)
  • ...
AGP Gradle Wrapper Support
2.3.3 3.3 / 4.6 ✔️
3.2.1 4.6 ✔️
3.5.3 5.4.1 ✔️
4.1.1 6.5 ✔️
7.0.4 7.0.2

注:AGP 即 Android Gradle Plugin

使用

  • RPX_VERSIONRelease Version
  • gralde Versions
  • AGP Versions

1、集成 jitpack 仓库

宿主/插件 项目根目录 build.gradle 中加入:

buildscript {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}

allprojects {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}

2、配置 宿主(host) 工程

在宿主工程根目录下 build.gradle 中加入:

buildscript {
    ...
    dependencies {
        classpath 'com.android.tools.build:gradle:2.3.3' // AndroidX 工程需升级到 3.2.0 及以上
        classpath "com.github.GitLqr.RePluginX:replugin-host-gradle:${RPX_VERSION}"
    }
}

在宿主 主 Module(app) 目录下 build.gradle 中加入:

dependencies {
    ...
    implementation "com.github.GitLqr.RePluginX:replugin-host-library:${RPX_VERSION}"
    // 注意:如果是 AndroidX 宿主工程,必须添加如下依赖 !!
    // implementation "androidx.localbroadcastmanager:localbroadcastmanager:1.0.0"
}

apply plugin: 'replugin-host-gradle'
repluginHostConfig {
    // enable = true // 是否启用插件功能,默认为true
    screenOrientation = 'landscape' // 坑位 Activity 方向(portrait / landscape)
    ...
}
  • enable:是否启用插件功能,默认为 true,宿主工程一般不会用到!
  • screenOrientation :坑位 Activity 的屏幕方向配置,默认不配置即为竖屏 portrait,如需横屏可配置为 landscape

3、配置 插件(plugin) 工程

在插件工程根目录下 build.gradle 中加入:

buildscript {
    ...
    dependencies {
        classpath 'com.android.tools.build:gradle:2.3.3' // AndroidX 工程需升级到 3.2.0 及以上
        classpath "com.github.GitLqr.RePluginX:replugin-plugin-gradle:${RPX_VERSION}"
    }
}

在插件 主 Module(app) 目录下 build.gradle 中加入:

dependencies {
    ...
    implementation "com.github.GitLqr.RePluginX:replugin-plugin-library:${RPX_VERSION}"
}

// 这个plugin需要放在android配置之后,因为需要读取android中的配置项
apply plugin: 'replugin-plugin-gradle'
repluginPluginConfig {
    enable = true // 是否启用插件功能,默认为true
    classExcludes = ["androidx.*"] // 移除class文件配置(正则表达式)
    classIncludes = ["androidx.fragment.app.FragmentActivity"] // 保留class文件配置(正则表达式)
    ...
}
  • enable:是否启用插件功能,默认为 true。配置为 false 时,插件工程将失去 RePlugin Transform 功能(Transform 很耗时),这意味着工程打包出来的就只是普通的 apk,但同时也恢复了原有的编译速度,一般只在快速开发工程时配置为 false。记得在正式出包前配置为 true 或将其注释掉。
  • classExcludes:移除 class 文件配置【正则表达式】,默认为空(不移除任何 class)。配置后,只要 class 文件的全限定名 满足该配置列表中的任意一项正则表达式时,都不会被打包进插件 apk 文件中,从而减少插件 apk 体积。
  • classIncludes:保留 class 文件配置【正则表达式】,默认为空。该配置主要是为了与 classExcludes 配合使用,当指定包路径下除了个别 class 文件外需要保留,而其余 class 文件需要移除时,可以在该配置列表中指定要保留的 class 文件全限定名。

技术要点

官方原文档

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].