---
title: "git使用"
author: "nnnnon"
date: "2010-11-04T11:21:56Z"
tags: []
categories: ["编程语言"]
slug: "git"
draft: false
lastmod: "2010-11-04T11:21:56Z"
id: 802559
url: "https://malijun.iteye.com/blog/802559"
---

<http://hi.baidu.com/i7521/blog/item/1223883dbae09b0ebba1674a.html>
具体可简化：

ssh-keygen -t rsa -C "xxx@gmail.com"
将.ssh/id_rsa.pub拷贝到GitHub网站
#ssh git@github.com
如果配置正确，显示
ERROR: Hi xxx! You've successfully authenticated, but GitHub does not provide shell access
Connection to github.com closed.

# git config --global user.name "xx"
# git config --global user.email xxx@gmail.com

到项目目录下面：
git add .
git commit -m "your first information"
git remote add origin git@github.com:xxx/new-project.git   
git push origin master

更新：
# git commit -a  -m "update information"   
# git push origin master