zoukankan      html  css  js  c++  java
  • github简单操作

    github首次安装使用

    在项目本地代码路径下,右击选择git bash here

    git init
    git add .
    git commit -m "first commit"  (本次提交的内容)
    git remote add origin https://github.com/xxxx.git (github上创建好的仓库地址)
    git push -u origin master  (这一句执行的时候 可能需要输入你的 git 账号 和密码)
    上面命令将本地的master分支推送到origin主机,同时指定origin为默认主机,后面就可以不加任何参数使用git push了
    解决github每次提交输入账号密码

    https://blog.csdn.net/wjb820728252/article/details/63803713

    gitbub提交代码(已关联过远程分支地址)
    git add .
    git commit -m "commitment details" (每次提交尽可能概况提交的内容,后续如果有问题,方便回退代码到历史指定版本) 
    git push
    github回退代码到历史指定版本

    1 通过git命令查询历史对应不同版本的ID ,或者在github上直接查看要回退的版本对应的ID

    git log --pretty=oneline

    2 恢复到指定历史版本

    git reset --hard ID

    3 把修改推到远程服务器

    git push -f -u origin master
  • 相关阅读:
    python的元类
    中国的互联网:草根与精英
    PEP8中文翻译
    一些重要的算法
    tornado模板语法
    C#l类与对象
    sql_ 存储过程
    SQL_触发器
    SQL_事务处理
    C#_方法
  • 原文地址:https://www.cnblogs.com/echoqi/p/10591542.html
Copyright © 2011-2022 走看看