`
tcspecial
  • 浏览: 916905 次
  • 性别: Icon_minigender_1
  • 来自: 深圳
社区版块
存档分类
最新评论

github的使用

阅读更多

     GIT是一个开源的分页式版本控制系统, Github 是GIT项目的托管网站,下面看看如何使用GIT管理我们的项目:

 

1. 安装git客户端

windows下安装tortoisegit,默认会安装mingw环境。也可以Cmder工具。

 

2. 生成密钥对

开始菜单打开Git Bash

ssh-keygen -C 'youemail@email.com'
cat ~/.ssh/id_rsa.pub
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDbAqRzxCOVa8O2/mGEDvqfjtONK1/a1uxGG82cmVtJ/o3GDPudymy6hlZ4oha02SrPU44jpc7wzvVPhruiDTgvQxGHt2DEm2ex7NdnvNQNjBciqhXt+zoiH/lvPDLBf/zdOwpyt3MFAS8myNgzD2iOOPczPDqbcf3dkDE/jiE2kmw1Mm9zQaNX5fCU/jYEL7vS9t2v6wGrSACmkoq6aH8wlPt9z8nlcFIhp7CScYJ24BiKYno/erFE0BMdhIjlN5P7kjVYyzWdW6ewPazf9Xw00kw5yTOYkJFjoZBbKZ98D2d53ddsL74YPvhDupEFP+Os0XEWN5wuooeazsRn youemail@email.com

     

 3. 登录github,拷贝密钥

Settings ---> SSH and GPG keys ---> New SSH key

 

测试:

$ ssh -T git@github.com
Hi youemail! You've successfully authenticated, but GitHub does not provide shell access.

 

4. 创建工程test

+ ---> New reposity ---> Create repository

 

5.上传本地test源码到github

mkdir ~/test 
cd ~/test

git init 
git config --global user.name "your name"
git config --global user.email "youremail@email.com"
 
touch README
git add README   
git commit -m 'first commit'
git remote add origin git@github.com:youremail/test.git

git push -u origin master -f
git pull --rebase origin master 

      

6. 删除仓库

进入test仓库后,点击右上角Settings ---> Delete this repository

   

Gitlab 与github 功能比较类似,但是gitlab 的私有仓库是免费的,值得一试。

 

 

 

 

 

 

 

分享到:
评论

相关推荐

    github 使用指南 官方中文

    这份"GitHub 使用指南 官方中文"是 GitHub 官方提供的帮助文档,旨在帮助中文用户更好地理解和使用 GitHub。 一、GitHub 基础概念 1. **仓库(Repository)**:在 GitHub 上,你的项目就是一个仓库,它包含了所有的...

    github使用教程github使用教程

    github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程github使用教程...

    Github使用教程.zip_zip压缩包

    Github使用教程.zip 身为程序员,怎么能不会使用github呢

    github使用文档-改进版1

    github使用文档 github使用文档

    moredoc-github使用教程

    moredocgolangdochub github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    IoTLink-github使用教程

    SpringBootVueMybatisRabbitMqMysqlRedis + github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    F2-github使用教程

    HTML5 Canvas github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    GitHub使用教程分享

    github使用教程GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub使用教程分享GitHub...

    novel-github使用教程

    novel Java Spring Boot 3 + Vue 3 Java github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    github使用方法(关注,持续更新)

    GitHub 使用方法详解 GitHub 是一个基于 Git 的代码托管平台,可以帮助开发者们更好地管理和协作开发项目。以下是 GitHub 使用方法的详细解释: 一、注册 GitHub 账号 在使用 GitHub 之前,需要注册一个 GitHub ...

    wukong-robot-github使用教程

    wukong-robot / ChatGPT github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    Rime键道输入法-github使用教程

    6RimeRIME github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    WukongCRM-11.0-JAVA -github使用教程

    CRM-Spring Cloud Alibaba +vue ElementUICRM+ github使用教程 github使用教程 github使用教程 github使用教程 github使用教程

    github使用

    GitHub使用总结

    GitHub使用教程.zip

    github使用教程GitHub使用教程.zip

    GitHub使用技巧.zip

    GitHub使用技巧.zip 1.在线编辑上传 2.留言时可以从剪贴板粘贴图片。会被上传到云端,并在markdown中整齐的显示出来 3.格式化代码 5.评论中超链接到另一个评论 6.文章中超链接到某行代码 7.项目板

    github使用教程.txt

    github使用教程

    github使用教程.rar

    github使用教程

Global site tag (gtag.js) - Google Analytics