How to checkout commit in GitKraken?

早过忘川 提交于 2019-12-03 14:27:59

问题


It seems to be impossible to checkout commits with GitKraken.

As you can see there is no option to checkout older commits, only Cherrypick commit but I don't know what this is good for.

EDIT: I was able to checkout with another git program (git bash) via console:

Now it looks like this in GitKraken:


回答1:


GitKraken (as of version 1.7) does not seem to offer a way to get into a detached HEAD mode, and check out a commit directly. Similarly, it will also not allow you to check out a tag (since that would also give you a detached HEAD).

So instead, you will have to create a (temporary) branch first which you can then check out.




回答2:


They finally implemented this feature yesterday (Sept. 25th, 2019).

Users can now enter a detached HEAD state by clicking the commit you wish to checkout and selecting Checkout this commit.




回答3:


You can make a UNDO in the top bar. Anothe option can be reset to another commit using the right click on the commit.




回答4:


The way you do this is by right clicking on your desired commit and select "Reset to this commit" and then choose "Hard - Discard all changes"



来源:https://stackoverflow.com/questions/39977015/how-to-checkout-commit-in-gitkraken

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!