博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
git 回滚版本
阅读量:7305 次
发布时间:2019-06-30

本文共 476 字,大约阅读时间需要 1 分钟。

hot3.png

先显示提交的log

$ git log -3
commit 4dc08bb8996a6ee02f
Author: Mark <xxx@xx.com>
Date:   Wed Sep 7 08:08:53 2016 +0800

    xxxxx

commit 9cac9ba76574da2167

Author: xxx<xx@qq.com>
Date:   Tue Sep 6 22:18:59 2016 +0800

    improved the requst

commit e377f60e28c8b84158

Author: xxx<xxx@qq.com>
Date:   Tue Sep 6 14:42:44 2016 +0800

    changed the password from empty to max123

回滚到指定的版本
git reset --hard e377f60e28c8b84158

强制提交
git push -f origin master

转载于:https://my.oschina.net/mengzhang6/blog/1591503

你可能感兴趣的文章
视频技术基础
查看>>
vue.js 使用小结
查看>>
CentOS 中安装NFS
查看>>
35 个在网页设计漂亮的滑块设计
查看>>
Memcached 结构分析
查看>>
42个非常有用的 HTML5 开发教程和学习资源
查看>>
如何找回Oracle中system,sys用户的密码
查看>>
跟我来之--(Windows 8 Consumer Preview安装图解)
查看>>
Revit API导出GBXML
查看>>
深入浅出说流水线
查看>>
【CUDA学习】高效访问24位RGB图像
查看>>
动态链接 - dll和so文件区别与构成
查看>>
[dataTables.js error] Uncaught TypeError: myTable.row is not a function
查看>>
Framebuffer原理、使用、测试系列文章,非常好的资料,大家一起学习
查看>>
android camera jni调用
查看>>
Linux学习笔记(三):系统执行级与执行级的切换
查看>>
10601 - Cubes(Ploya)
查看>>
C 标准库 - <locale.h>
查看>>
Android TV 开发(4)
查看>>
Groovy Goodness: Removing Duplicate Elements in a Collection - Messages from mrhaki
查看>>