How to Use Git and GitHub

原创 2016年05月31日 15:01:36

Lesson1

Finding Diffs Between Larger Files

这个课程让我学会用命令行自动比较两个文件的不同
下载材料两个javascript文件:
game_old.js
game_new.js
打开命令行cmd,输入cd downloards进入存放上述两文件的路径
然后输入FC game_old.js game_new.js (FC = file compare)
回车,显示结果

这里写图片描述

Reflect: Using diff to Find Bugs

Choose Sublime as a text editor
Make sure you can launch your editor from the command line
Windows
方法:
Find the directory where Sublime is located for you. For many people, this is C:/Program\ Files/Sublime\ Text\ 2/sublime_text.exe. To test this, run ls C:/Program\ Files/Sublime\ Text\ 2 within Git Bash. You should see sublime_text.exe listed. If you get the error No such file or directory, Sublime is located somewhere else for you and you’ll need to find it. For example, it might be under C:/Program\ Files\ (x86)`.

Run the following command in Git Bash: echo ‘alias subl=”C:/Program\ Files/Sublime\ Text\ 2/sublime_text.exe”’ >> ~/.bashrc If Sublime was in a different directory for you in step 1, use that directory.

Close and re-open Git Bash.

Type subl in Git Bash. If Sublime opens no further steps are required. If Sublime does not open continue with steps 5 - 7.

Test .bashrc by running the command source ~/.bashrc in Git Bash and retry typing subl to start sublime. If Sublime doesn’t start check the contents of the file ~/.bashrc created in step 2.

To ensure the .bashrc file contents is loaded each time you open Git Bash, edit ~/.bash_profile and add the following two lines. (Reference)

if [ -r ~/.profile ]; then . ~/.profile; fi

case “$-” in i) if [ -r ~/.bashrc ]; then . ~/.bashrc; fi;; esac

Close and re-open Git Bash. Type subl in Git Bash to check it starts correctly.

Set up your course workspace

版权声明:本文为博主原创文章,未经博主允许不得转载。

Sublime Text 3 配置文件详解

Sublime Text 3 配置文件 // While you can edit this file, it's best to put your changes in // "User/Pre...
  • Code_Nothing
  • Code_Nothing
  • 2015年03月13日 14:42
  • 3513

Git use summary (2)

1、Writing int the front  使用git已经有很长一段时间了,从最初的不熟悉,误解,到现在的熟悉,惊叹于git的优雅与神奇,这大概就是git带给我们每一个开发者的魅力吧!恰逢最近看...
  • duankaifei
  • duankaifei
  • 2015年01月01日 15:24
  • 839

How to use github

了解Github的基本功能:也就是为什么用Github。 forward from the original url (http://www.zhihu.com/question/20070065)...
  • dbdxliudiwen
  • dbdxliudiwen
  • 2014年11月20日 15:00
  • 182

Github how to use

Make a commit On GitHub, saved changes are called commits. Commits are pretty glorious, because a...
  • zhao4238339
  • zhao4238339
  • 2014年10月27日 18:19
  • 164

how to use github on ubuntu

1 Installing Git for Linux Download and install Git for Linux : sudo apt-get install git   ...
  • seamanj
  • seamanj
  • 2016年02月17日 20:37
  • 390

github中ssh和https提交的区别

从github上clone一个项目到本地的时候,有use HTTPS和use SSH两种方式,这两种主要是在push项目到github上时有所不同。完成一个push操作,需要对其内容进行安全管理,这里...
  • ITzhongzi
  • ITzhongzi
  • 2017年03月15日 23:05
  • 1076

Xshell无法链接本地虚拟机

本地cmd能够ping同虚拟机的IP地址,但是xshell链接时提示如下: Connecting to 10.110.31.151:22... Could not connect to...
  • KoalaY_Doctor
  • KoalaY_Doctor
  • 2016年01月05日 10:34
  • 2632

Github桌面版使用方式(How to Use Github [Desktop Version])

Github是一个流行的代码管理网站,同时也是全球最大的同性交友网站(滑稽)。Github网页上你可以自由地托管自己的项目,也可以fork别人的项目过来玩耍,非常之方便,今天笔者就来介绍一下githu...
  • qq_32690999
  • qq_32690999
  • 2017年08月23日 11:36
  • 660

how to use git

  • beiquandeng
  • beiquandeng
  • 2015年11月25日 09:15
  • 403

How To Use Git Branches

This article is the third installment in the "Using Git" series. It assumes that you have read both ...
  • xingqingly
  • xingqingly
  • 2016年11月13日 19:18
  • 197
内容举报
返回顶部
收藏助手
不良信息举报
您举报文章:How to Use Git and GitHub
举报原因:
原因补充:

(最多只允许输入30个字)