Coder Social home page Coder Social logo

zhangtian1993 / fataar-gradle-plugin Goto Github PK

View Code? Open in Web Editor NEW

This project forked from mobbeel/fataar-gradle-plugin

0.0 0.0 0.0 127 KB

Gradle plugin to help embed dependencies in generated AAR artifact

Home Page: https://plugins.gradle.org/plugin/com.mobbeel.plugin

License: Apache License 2.0

Groovy 82.67% Java 0.87% Makefile 1.32% C++ 15.15%

fataar-gradle-plugin's Introduction

Mobbeel fat AAR Gradle plugin

In Mobbeel we work with a complex hierarchy of modules that in turn must embed other dependencies in the resulting AAR. To do this we use this Gradle plugin that allows to merge a project and its dependencies in the same AAR (fat-aar).

Issue reporting are welcome to continue to improve this plugin.

Plugin work with Android gradle plugin 3.0.0 o higher

Features

  • Support external dependencies from workspace (example: api "com.mobbeel:my-lib:1.0.0")

  • Support internal dependencies (example: api project(':My-lib-module'))

  • Support internal/external native dependencies

  • Support internal/external AAR dependencies

  • Support add transitive dependencies from pom.xml on jar dependencies

  • [NEW] Merge resources from AAR dependencies

How to use?

  1. Configure your buildscript to include the plugin:
buildscript {
  repositories {
    maven { url "https://plugins.gradle.org/m2/" }
  }
  dependencies {
    classpath "com.mobbeel.plugin:fat-aar:2.0.1"
  }
}
  1. Apply the plugin on the top of your library module build.gradle:
apply plugin: "com.mobbeel.plugin"
  1. Mark with 'api' configuration dependecies that need embed on the final AAR:
dependencies {
    api "com.mobbeel:my-lib:1.0.0"  // <- Embed external dependency from any repository
    api project(':My-lib-module')   // <- Embed internal dependency on workspace

    ...
}

Add to fat AAR all transitive dependencies

By default, the transitive dependencies that define a dependency are not added to the fat AAR. You can add them by adding these settings:

aarPlugin {
    includeAllInnerDependencies true  // It's false for default
}

fataar-gradle-plugin's People

Contributors

oscarcpozas avatar andreyneura avatar liushuai42 avatar rafaelitajuba avatar rafaelring avatar jonbryantnz avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.