zoukankan      html  css  js  c++  java
  • git 常用命令

    文件管理

    git init在本地创建仓库

    git add .  将所有文件添加版本控制

    git commit -m "add"

    git remote add origin https://github.com/xmxkkk/git_lession.git 将本地仓库和远程仓库关联气来

    git push origin master 将本地仓库推送到master

    git checkout -- readme.txt  取消文件修改

    git rm readme.txt 删除文件

    版本管理

    git branch 查看分支

    git branch dev 创建版本,如果没有任何文件改变,不能推送

    git checkout dev 切换版本

    git merge dev 将dev上的修改切换到master

    tag管理

    git tag

    git tag v1.0

    git tag -d v1.0

    git push origin v1.0推送tag   v1.0

    git push origin --tags推送全部tag

    git push origin :refs/tags/v1.0 删除远程tag

     

    生成github sshkey

    ssh-keygen -t rsa -C "908581016@qq.com"

    然后将这个pub key添加到github

  • 相关阅读:
    python_linux系统相关配置
    python_字典dict相关操作
    python_传参
    mapreduce 学习笔记
    linux 常用命令
    C++ stringstream介绍,使用方法与例子
    C++/C++11中std::numeric_limits的使用
    C++中string erase函数的使用
    C++中accumulate的用法
    malloc的用法和意义
  • 原文地址:https://www.cnblogs.com/xmxkkk/p/7324050.html
Copyright © 2011-2022 走看看