zoukankan      html  css  js  c++  java
  • Windows平台使用git bash管理github中的工程

    1、安装git bash

     msysgit(http://code.google.com/p/msysgit/)

    2、创建SSH key

    右键点击目录,

    ssh-keygen.exe -C "your_email@github" -t rsa

    生成的key存放位置:

    SSH key的原理:

    3、拷贝公钥到github

    测试一下公钥是否可用

    ssh -T git@github.com

    4、从github拷出你的代码

    拷出

    $git clone git://github.com/schacon/simplegit.git

    5、开始向github提交或
    提交
      5.1 配置
      git config --global user.name "Your Name"
      git config --global user.email your_email@gmail.com
     
    5.2 创建Repository
     
    1 mkdir clrs
    2 cd clrs
    3 git init
    4 touch README
    5 git add README
    6 git commit -m 'first commit'
    7 git remote add origin git@github.com:your_name/clrs.git
    8 git push origin master
     
    5.3 提交已经存在的Repository
     
    1 cd existing_git_repo
    2 git remote add origin git@github.com:your_name/clrs.git
    3 git push origin master
     
    参考:
    http://blog.lmlphp.com/archives/7/The_use_tutorial_of_git_bash_and_how_to_start_with_github
    http://www.cnblogs.com/zdz8207/archive/2012/04/27/git-github.html
  • 相关阅读:
    android-手势密码
    MS SQL 技巧总结--持续更新
    MySQL 笔记一
    spring 家族
    Java集合
    javaScript
    java 知识点随记
    MySQL 知识点随记
    odoo 权限杂记
    win10 Ubuntu子系统安装&odoo10社区版安装
  • 原文地址:https://www.cnblogs.com/superpig0501/p/4658487.html
Copyright © 2011-2022 走看看