Git Product home page Git Product logo

panda.android's Introduction

panda.android

目标

提供一个完善的Android App应用开发库。其特质为 提升开发效率、缩短开发工期、降低维护成本。

引入方式

  1. 在项目的build.gradle中添加maven url。
buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.1.0'
        classpath 'com.neenbedankt.gradle.plugins:android-apt:1.7'
        classpath 'com.oguzbabaoglu:butterfork-plugin:1.0.0'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        jcenter()
        maven { url "https://jitpack.io" }
        // 这句是重点,重点,重点
        maven { url "https://github.com/tianci-panda/mvn-repo/raw/master/" }
    }
}
  1. 在应用模块的build.gradle中添加库的引用
apply plugin: 'com.neenbedankt.android-apt'
apply plugin: 'com.oguzbabaoglu.butterfork-plugin'

dependencies {
    compile 'panda.android:lib:0.1.+@aar'
    compile 'com.android.support:support-v4:23.+'
    compile 'com.android.support:appcompat-v7:23.+'
    compile 'com.jakewharton:butterknife:7.0.1'
    compile 'de.greenrobot:eventbus:2.4.0'
    compile 'com.google.code.gson:gson:2.2.4'
    compile 'com.readystatesoftware.systembartint:systembartint:1.0.3'
    compile 'com.umeng.analytics:analytics:latest.integration'
    compile('com.weiwangcn.betterspinner:library:1.1.0') {
        exclude group: 'com.android.support', module: 'appcompat-v7'
    }
    compile 'net.danlew:android.joda:2.9.1'
    compile 'com.oguzbabaoglu:butterfork-binder:1.0.0'
    apt 'com.oguzbabaoglu:butterfork-compiler:1.0.0'
    compile 'com.github.chrisbanes:PhotoView:1.2.6'

    compile 'com.nineoldandroids:library:2.4.0'
    compile 'cn.bingoogolapple:bga-refreshlayout:1.1.0@aar'
    compile 'com.android.support:recyclerview-v7:23.0.+'
}

知识沉淀

财富自由·技术·Android

如何为PandaAndroidLib贡献代码

初级贡献者:new pull request

  1. 注册git账号。
  2. fork panda.android ,下载到本地,记下本地地址,比如:/Users/shitianci/work/Lab/panda.android
  3. 本地修改,同步到自己的repo后。创建pull request,发送给panda.android。

中级贡献者:Collaborators

  • 将git账号发送给Panda,成为项目的Collaborators。
  • 直接在panda.android的dev分支下开发即可。

高级贡献者:同步维护aar包的编译和发布

  • 取得mvn-repo的修改权限。
  • clone mvn-repo 到本机。
  • 找到PandaAndroidLib下的gradle.properties,进行发布配置。
# **mvn-repo**的本机目录
aar.deployPath=/Users/shitianci/work/Lab/mvn-repo
# VersionCode的格式为 发布当天的yyyyMMDD+自增长的两位数
VERSION_CODE=2016032102
# VersionName的格式为 大版本.小版本.VersionCode (VersionCode会自动拼接上去)
VERSION_NAME=0.1
  • 执行./gradlew :PandaAndroidLib:uploadArchives windsws执行gradlew :PandaAndroidLib:uploadArchives
  • 将生成文件同步到mvn-repo即可。

分支管理

  • 主分支master:存放release的版本。每个版本都对应一个tag,并在mvn-repo发布。
  • 开发分支dev:日常开发活动分支。可以用来生成代码的最新隔夜版本(nightly)
  • 临时性分支:用于应对一些特定目的的版本开发。属于临时性需要,使用完以后,应该删除,使得代码库的常设分支始终只有Master和Develop。
    • 功能(feature)分支
    • 预发布(release)分支
    • 修补bug(fixbug)分支

具体理解参考阮一峰:Git分支管理策略

如何初始化一个基于PandaAndroidLib的项目

参考:[Android流水化开发]工序1:初始化项目框架

主要更新日志

2016年

总共更新17次。核心内容沉淀在孚睿科技·ANDROID知识总结中,支持 海南3G v3.1;机务段v1.3;深海电商;成长记忆;借易贷{1.0、2.0、3.0}、ACCA、时间农夫、蜘蛛社群 等8款产品。

主要更新内容为:

  1. 建立流水化开发的理念,持续积累。
  2. 用maven构建产物,方便Gradle方式引用库。
  3. 基于CommonPullToRefresh封装出简易的下拉刷新框架。
  4. 基于litehttp封装BaseRepositoryCollection的方法,一行访问网络,获取常规的json和file数据。
  5. 将网络接口错误码处理移动到BaseApp里面,统一处理。

panda.android's People

Contributors

tianci avatar shitianci avatar olivinevip avatar

Watchers

James Cloos avatar  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.