关于git, github

Git 堪称版本控制瑞士军刀。这个可靠、多才多艺、用途多样的校 订工具异常灵活,以致不易掌握,更别说精通了。

正如Arthur C. Clarke所说,足够先进的技术与魔法无二。这是学习Git的好办法:新手 不妨忽略Git的内部机理,只当小把戏玩,借助Git其奇妙的能力,逗逗朋友,气气敌人。

为了不陷入细节,我们对特定功能提供大面上的讲解。在反复应用之后,慢慢地你会理 解每个小技巧如何工作,以及如何组合这些技巧以满足你的需求。


Git命令:  http://gitref.org/creating/

Github的一个10分钟在线小教程: try.github.com

Git高阶, 一些深入讲解: http://www-cs-students.stanford.edu/~blynn/gitmagic/intl/zh_cn/

Git for computer scientists: http://eagain.net/articles/git-for-computer-scientists/

Git最新版本地址: https://launchpad.net/~git-core


Git命令:

1.显示有几个remote:   $ git remote show

2.显示具体一个remote 信息 :  $ git remote show master

3. 如果git版本1.7.9以及以后,连接github用https, 每次会要求输入密码,这个指令可以让你15分钟以内不需要输入密码:

$ git config --global credential.helper cache

或者让时间更长一点: $ git config credential.helper 'cache --timeout=3600'

4. 如果git版本1.7.9以前,

With versions of git before 1.7.9, this more secure option is not available, and you'll need to change the URL that your origin remote uses to include the password in this fashion:

https://you:password@github.com/you/example.git

... in other words with :yourpassword after the username and before the @. You can set a new URL for your origin remote with:

git config remote.origin.url https://you:password@github.com/you/example.git

Make sure that you use https and you should be aware that if you do this, your github password will be stored in plaintext in your .git directory, which is obviously undesirable.







  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值