zoukankan      html  css  js  c++  java
  • Git使用命令

    一、配置git ssh

    1、检查用户名和邮箱是否配置

    git config --global  --list 

    2、配置用户名和邮箱

    git config --global  user.name "这里换上你的用户名"
    git config --global user.email "这里换上你的邮箱"

    3、生成ssh秘钥(将生成公钥上传至github或者gitee)

    ssh-keygen -t rsa -C "这里换上你的邮箱"

    二、提交到本地版本库

    1、初始化git仓库配置

    $ git init

    2、添加文件到版本库

    git add .

    3、把添加的文件提交到版本库,并填写提交备注

    git commit -m "first commit"

    三、版本库文件提交到远程仓库

    1、本地库与远程仓库关联

    $ git remote add origin http://192.168.1.183/git/pspb.git

    2、将文件推送至远程分支

    git push -u origin master   
    git push origin master      

    3、将远程仓库拉取下来

    git pull origin master
  • 相关阅读:
    CCF201604试题
    CCF201512试题
    CCF201509试题
    CCF201509试题
    CCF201503试题
    CCF201503试题
    CCF201412试题
    CCF201412试题
    CCF201409试题
    CCF201409试题
  • 原文地址:https://www.cnblogs.com/myLeisureTime/p/12957797.html
Copyright © 2011-2022 走看看