如何提交Code到google open source android gerrit
来源:互联网 发布:如何安装redhat linux 编辑:程序博客网 时间:2024/06/07 19:33
也许你在进行android开发的时候会发现一些android原生的问题,那么你可以提交issue到google issue网站上,
当然在提交的时候最好能先搜一下在google issue上是否已经有相关的CR已经提交过了,那么有就可以参考
一下遇到该问题的Coder们都怎么分析的,申请一个gmail帐号你也可以和大家一起讨论,那么如果你想要将
自己对该问题的修改提交到android的仓库里应该怎么办呢?这就是本篇文章要讲述的主要内容:如何提交你
的修改到Android gerrit上。
首先来了解两个官方网站:
1.android issue list
url: http://code.google.com/p/android/issues/list
这个网站上会有目前提交到android上的所有issue,这里你可以提交issue,管理你的issue,也可搜索已有的issue
2.android gerrit
url:https://android-review.googlesource.com
这个网站上会有android release上所有提交,可以查看所有提交,管理自己的提交,添加android&google的人员
对你的提交进行review.
了解以上两个官方网址之后,接下来我们就做提交code的准备了,前提是你需要提交的code已经准备好,我主要是基于个人第一次提交code的经历将过程讲述一遍,如果你想要
看官方的详细说明可以看 android 官网的 Submitting Patches 这个页面的描述。
基于本地(ubuntu)有android源码滴同学,提交code到android 仓库步骤
1.将自己的code修改完毕并验证过OK
2.配置android gerrit
1) 用gmail登录到https://android-review.googlesource.com
2) 点击右上角用户名进入settings ---> Agreements ---> New Contributor Agreement一路操作下去各种agree就行了
3) 到 establish a password 上按照说明在本地shell执行一遍就ok
3.cd 修改code所在仓库的.git目录下
vi config
按照如下方式添加aosp的remote信息,以5.0 frameworks/webview为例
[remote "aosp"]
url = https://android.googlesource.com/platform/frameworks/webview
review = https://android-review.googlesource.com
projectname = platform/frameworks/webview
fetch = +refs/heads/*:refs/remotes/aosp/*
4.1) git fetch aosp # fetch aosp远程仓库
2) git branch -r |grep aosp
fetch完成之后通过上面这条命令可以看到如下aosp相关的分支
aosp/chromium-dev
aosp/idea133
aosp/idea133-weekly-release
aosp/jb-mr2-dev
aosp/jb-mr2-release
aosp/jb-mr2.0-release
aosp/jb-mr2.0.0-release
aosp/kitkat-cts-dev
aosp/kitkat-dev
aosp/kitkat-mr1-release
aosp/kitkat-mr1.1-release
aosp/kitkat-mr2-release
aosp/kitkat-mr2.1-release
aosp/kitkat-mr2.2-release
aosp/kitkat-release
aosp/kitkat-wear
aosp/l-preview
aosp/lollipop-dev
aosp/lollipop-release
aosp/lollipop-wear-release
aosp/master
aosp/tools_r22.2
3) git checkout -b aosp_master aosp/master #创建本地aosp_master分支
4) git config user.name "XXX" #配置提交的用户名和邮箱,这里的name和email需要
和android-review.googlesource.com上用户设置下profile中保持一致。
git config user.emai XXX@gmail.com
5) git add, git commit这些命令几乎是日常就不说了,注意git log看一下提交message中一定要是
android gerrit上的用户信息(name&email),不然会提交失败,错误提示类似如下:
remote: ERROR: In commit 2a34a535511c4e4b6f6baf91b6eedca2fcb37a1a
remote: ERROR: committer email address xxx@163.com
remote: ERROR: does not match your user account.
remote: ERROR:
remote: ERROR: The following addresses are currently registered:
remote: ERROR: xxxx@gmail.com
6) repo upload . --br aosp_master # 提交到android gerrit 一路yes就可以了
7) 在你所修改的模块中查找该模块owner名字,在gerrit上add他们对你的code进行review
铛铛....到android-review.googlesource.com上查看你的提交已经上去啦~~
参考
1.https://source.android.com/source/submit-patches.html
- 如何提交Code到google open source android gerrit
- 如何给google提交code -- 原声问题修改如何提交到google gerrit上
- Gerrit&Jenkins for source code
- http://code.google.com/p/zf-open-source-as-utils/
- [Sharing] Open Source LBS Navigation, Routing Android App Source Code
- 备忘-提交代码到google code
- Gerrit 提交更改到gerrit服务器
- [Sharing] Google Map Android App Source Code
- iOS open source code
- google open source
- 通过git 提交代码到gerrit上进行code review的6个步骤
- 局域网用户间避开gerrit高速传输Android Source Code的方法
- Gerrit如何提交大量代码
- 如何通过svn给google code上传source
- 国内如何下载 Android source code
- [YouTube] Android Demo -- An Open Source Platform from Google.com
- LG Open source code获取
- git版本控制工具提交到gerrit
- android带进度条的button
- Android笔记使用SharedPreferences进行数据存储
- 微信公众号开发之uwsgi拒绝post请求
- Contest1319 - 期末习题汇总(二) 计算机基础---进制转换相关
- MySQL数据类型说明
- 如何提交Code到google open source android gerrit
- JDK中设计模式
- 看到的一段话,随便发发
- 【PAT】 1004成绩排名
- MYSQL数据库隔离级别
- MFC radio 选择失效
- php点击生成并下载csv文件
- js call()方法!
- use scalar properties for primitive data types