gitlab反向合并错误后的恢复
现有分支提交历史有错误的
1.从历史提交新建一个分支
git checkout -b 2.1.b f22c1f18f701acfbd10a5a1d22be05af612af9d3
2.从现有分支复制提交的版本号
3.切到到新分支,粘提交的版本号,执行
git cherry-pick b1a8372c97e7ed1ac25d9b91b2a8b3348fe78d8b 5095d3270770e8779ab753379c07bf2d7ed4a34e b1ab62d0a5d34708e963d2a05d4b61a8350f6c2d 714f58108c3e5aeb96fe4081c4dcfe140d316d56 aaa593a2c9f9954ebec58b8e7cb33282a486e42a b158d3717e58d439fc348109b8ff9b1c7d4ef44f 99329dccdec1922f84794643407f029e783fdf3c 14988e2bb7b1f8f1d5d2b663f9ffebabeec132bf a89f471bdb0527ea3d4b21d39be9715f1c41d591 ce9a267a840ed91961c4dbdfd99ff93ff5c67425 b54d1c1b27f8edb4f1d1171c2264f0475dbec00e a11631db42cac0d131067a0c40bd7669d275534c a5114900d191bef0a67ca2a12df36407b4414a6a
4.提交
文/程忠 浏览次数:0次 2024-06-11 12:32:02
1.从历史提交新建一个分支
git checkout -b 2.1.b f22c1f18f701acfbd10a5a1d22be05af612af9d3
2.从现有分支复制提交的版本号
![](http://image.highersoft.net/git_copy_version_1718080309063.png?imageView2/2/w/1600/q/100|imageslim)
3.切到到新分支,粘提交的版本号,执行
git cherry-pick b1a8372c97e7ed1ac25d9b91b2a8b3348fe78d8b 5095d3270770e8779ab753379c07bf2d7ed4a34e b1ab62d0a5d34708e963d2a05d4b61a8350f6c2d 714f58108c3e5aeb96fe4081c4dcfe140d316d56 aaa593a2c9f9954ebec58b8e7cb33282a486e42a b158d3717e58d439fc348109b8ff9b1c7d4ef44f 99329dccdec1922f84794643407f029e783fdf3c 14988e2bb7b1f8f1d5d2b663f9ffebabeec132bf a89f471bdb0527ea3d4b21d39be9715f1c41d591 ce9a267a840ed91961c4dbdfd99ff93ff5c67425 b54d1c1b27f8edb4f1d1171c2264f0475dbec00e a11631db42cac0d131067a0c40bd7669d275534c a5114900d191bef0a67ca2a12df36407b4414a6a
4.提交
相关阅读
评论:
↓ 广告开始-头部带绿为生活 ↓
↑ 广告结束-尾部支持多点击 ↑