测试

测试

测试分享!

  • 图片

    background

  • 代码块

    git init 
    git config user.name MeerOst
    git config user.email 3429551578@qq.com
    git config --global user.name MeerOst
    git config --global user.email 3429551578@qq.com
    git status
    git add hello.txt
    git rm --cached hello.txt #删除暂存区
    git commit hello.txt 
    git commit -m "第二次提交" hello.txt 
    git log
    git log --pretty=online
    git log --online#只显示历史版本,不显示前面的版本
    git relog
    git reset --hard 37djxjj8 
    git reset --hard HEAD^ #只能回退
    git reset --hard HEAD^^^ #回退三个版本
    git reset --hard HEAD~3 #只能回退,这里是回退三个版本
    git help reset #获取reset的帮助信息
    git reset --sort 37djxjj8 #改变本地库指针
    git reset --mixed 37djxjj8 #改变本地库和缓存区指针
    git reset --hard HEAD #删除文件并添加到缓存区后的文件找回
    git diff hello.txt #和暂存区进行比较
    git diff HEAD hello.txt #和当前指针位置所指的版本进行比较
    git diff HEAD hello.txt #和当前指针位置所指的删一个历史版本进行比较
    git branch -v #查看当前的所有分支
    git branch hot_fix #新建分支
    git checkout hot_fix #切换分支
    git merge hot_fix #合并分支
    vim hello.txt & git add hello.txt & git commit -m "HeBin" #解决合并冲突
    git remote -v #查看已经保存的运程库
    git remote add origin https://github.com/MeerOst/WeChat.git #添加origin远程库
    git push origin master #推送到远程的master分支
    git fetch origin master
    git checkout origin/master
    git merge origin/master
    cd ~
    ssh-keygen -t rsa -C 3429551578@qq.com
    cd ~/.ssh
    cat id_rsa.pub
    ipconfig /flushdns
    
  • 待续

posted @ 2023-09-30 11:38  Emaw  阅读(59)  评论(0编辑  收藏  举报