android底层开发入门(2)-git与repo
来源:互联网 发布:mocha跟踪数据导入ae 编辑:程序博客网 时间:2024/06/07 04:19
git and repo
在网上我大把介绍git的教程与原理在这里便不做详细的介绍了·在这里我主要做的是对git做一些笔录
- 安装git
sudo apt-get install git
- 配置用户信息
git config --global user.name "*****" git config --global user.email "*****" git init
- 在工作目录中初始化新仓库
git init
- 检查当前文件状态
git status
- 添加新文件
git add readme.txt git add -A
- 提交更新
git commit -m "****" //***为你的标记
- 查看提交历史
git log
- 分支的新建
git checkout -b [branch]
- 查看分支
git branch
- 将提交从一个分支拉到另一个分支
git cherry-pick [commit id]
- 将另外一个分支并到当前分支
git checkout [current branch] git merge [branch]
至于如何链接服务器,可以参考 git使用系列(1)-使用SSH密钥连接Github【图文教程】
git的远程操作
- 从服务器上抓code
git clone *******
- 查看远端
git remote -v
- 查看所有分支
git branch -a
- 查看远端分支
git branch -r
- 跟踪远端工作目录
git pull
Repo
它是 Google 开发的用于管理 Android 版本库的一个工具·它只是用python对git进行了封装·
因为我们无法访问google的网站,因此在没有代理的情况下基本上算是用不到了吧·
- 同步项目
repo sync -c -d
- 建立本地分支
repo start <newbranch>
- 检查状态
repo status
0 0
- android底层开发入门(2)-git与repo
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- Git与Repo入门
- 2015年蓝汛面试题
- 沈阳站之后
- android开发之shape详解
- 三星Galaxy Note5职场轻态度 对职场人士“减负”的启示
- Git的一些命令
- android底层开发入门(2)-git与repo
- 二叉树的实现
- PowerDesigner中导入MYSQL数据库结构的步骤
- android开发游记:自定义实现图片轮播器和启动页面滚动
- Android消息通信之无所不能的第三方开源项目EventBus
- 技能学习过程
- 多个文件预览
- json错误信息记录
- swift开发笔记14 - 解析json数据文件