首先我参考了hello_my_show和梦痕_sky的博客,表示感谢

android studio对于git的支持是很好的,这节课我们拉讲解怎么使用git可视化工具来clone project和提交修改

!!!!!!!!!!!!!android studio的git安装配置

1.首先下载git,在网址http://git-scm.com/downloads

2..配置身份、验证是否成功(方便提交代码知道是谁提交的)如下图

3.在studio中配置git插件:File->Setting->Version Control->Git, 然后选择你本地的Git安装路径(需要定位到bin目录下的git.exe),然后点击Test测试一下,结果如下图:那么恭喜你,你已经设置成功了!

4.将项目初始化git项目(git init),操作如下:VCS->Enable Control Integration->Select “Git”.



完成后会出现红框内的按钮

到现在为止,安装好了

!!!!!!!!现在讲解使用过程

上传到!!!!!github

1.上传项目到Github前的准备->登陆Github(没有Github账号的请自行去注册)

2.share到Github(VCS>Import into Version Control>Share Project on GitHub)

3.添加仓库名称和描述

4.选择要提交的文件,并对此次提交做一个描述,对比第四步的note,是不是发现我们ignore掉的文件都没在此出现!

5.登陆Github,查看仓库

6.既然Github是用来分布式控制版本系统,那我们如何将已经上传到Github的项目Clone到本地呢 1、VCS->Checkout from Version Control->GitHub,如图选择想要克隆的项目,设置好目录和项目名称,点击Clone即可。Android Studio 会在本地新建一个Project.

!!!!!!!使用git讲解

1.为git添加remote,在这一步中,studio没有为我们提供可视化的GUI,得用Git工具了。找到并打开git安装目录下面的Git Bash,将目录切换到项目的目录,然后输入git添加remote的命令,例如:git remote add origin “https://github.com/xxx/xxx.git“.

2.将代码添加到VCS(git add),选中要提交的文件->VCS->Git->Add,

3.提交变化(git commit),VCS->Commit Changes,如下图,在提交的时候可以选择Commit and Push,就可以直接push到服务器。

4.Git Push,VCS->Git->Push.

5.如果要是clone project到studio,如下图,

!!!!!如果使用了分支的命令不太一样

1.往下clone代码是:vcs –>update projects

2.上传代码: vcs–>commit changes

Android studio使用git-android学习之旅(79)的更多相关文章

  1. 或许是介绍Android Studio使用Git最详细的文章

    欢迎访问我的个人博客转发请注明出处:http://www.wensibo.top/2017/03/12/GitOnAS/ 前言 本文较长,图片很多很多,流量党慎入 使用Git已经有一段时间了,但是之前 ...

  2. Android studio测试软件——Monkey学习及运用

    Android studio测试软件——Monkey学习及运用 在第十五周的个人博客上,王老师安排我们根据最终的团队大作业所用的软件(Android studio)进行软件测试的介绍,而我选择的是基于 ...

  3. Android studio使用git教程

    ①下载Git工具,配置到Android studio中 http://git-scm.com/downloads ------------------------------------------- ...

  4. Android studio配置Git

    Android studio配置Git 1.下载window 版git并安装:下载地址 2.Android Studio设置git插件:File->Setting->Version Con ...

  5. Android Studio配置Git及Git文件状态说明

    Android Studio配置Git还是比较简单的,麻烦的是可能中间出现各种问题.如果你想了解或感兴趣,请往下看. 首先你得下载Git客户端,网址:http://git-scm.com/downlo ...

  6. Android Studio中Git和GitHub使用详解

    一.Git和GitHub简述 1.Git 分布式版本控制系统,最先使用于Linux社区,是一个开源免费的版本控制系统,功能类似于SVN和CVS.Git与其他版本管理工具最大的区别点和优点就是分布式: ...

  7. Android Studio 通过 git update 或者 pull 的时候出错及解决办法

    Android Studio 通过 git update 或者 pull 的时候出错,log 如下: Couldn't save uncommitted changes. Tried to save ...

  8. Win环境 Android Studio使用Git 教程 ( 一 )

    一. 安装 下载安装完成Git后 进入命令行 输入命令git --version,如果能显示版本则说明安装成功,如果没有显示版本,需要配置环境变量: 在path中添加git的安装位置 二 . 配置信息 ...

  9. Android Studio快捷键【Android学习入门】

    Studio快捷键[Android学习入门]" title="Android Studio快捷键[Android学习入门]"> 提示 Ctrl+P方法参数提示 Ct ...

  10. Android Studio(八):Android Studio设置教程

    Android Studio相关博客: Android Studio(一):介绍.安装.配置 Android Studio(二):快捷键设置.插件安装 Android Studio(三):设置Andr ...

随机推荐

  1. Numpy函数学习--genfromtxt函数

    genfromtxt函数 今天学习时遇到了genfromtxt函数 world_alcohol = numpy.genfromtxt("world_alcohol.txt",del ...

  2. Python3 基础语法

    编码 默认情况下,Python 3源码文件以 UTF-8 编码,所有字符串都是 unicode 字符串. 当然你也可以为源码文件指定不同的编码: # -*- coding: cp-1252 -*- 标 ...

  3. Android文件大头10G

    这个玩意直接10G....记录下. C:\Users\xn\AppData\Local\Android\sdk\system-images\android-23

  4. postgresql跨服务器复制数据库

    假设名为dbname数据库需要从A服务器拷贝到B服务器 接收服务器B postgres用户 需先重置B服务器postgres系统用户的密码,使之与数据库用户postgres一致: passwd -d ...

  5. JS——2048(支持触屏及键盘操作)

    <html> <head> <title>2048</title> <style type="text/css"> ta ...

  6. Programming In Scala笔记-第十七章、Scala中的集合类型

    本章主要介绍Scala中的集合类型,主要包括:Array, ListBuffer, Arraybuffer, Set, Map和Tuple. 一.序列 序列类型的对象中包含多个按顺序排列好的元素,可以 ...

  7. HDFS基本原理及数据存取实战

    ---------------------------------------------------------------------------------------------------- ...

  8. For oracle databases, if the top showing the oracle database, then oracle process is using the top c

    Note 805586.1   Troubleshooting Session Administration (Doc ID 805586.1)Note 822527.1   How To Find ...

  9. Linux for sougou ping yin (http://pinyin.sogou.com/linux/help.php)

    安装指南 Ubuntu / Ubuntu Kylin 14.04 LTS 版本 只需双击下载的 deb 软件包,即可直接安装搜狗输入法. Ubuntu 12.04 LTS 版本 由于 Ubuntu 1 ...

  10. x264源代码简单分析:宏块分析(Analysis)部分-帧间宏块(Inter)

    ===================================================== H.264源代码分析文章列表: [编码 - x264] x264源代码简单分析:概述 x26 ...