如何使用smartgit进行结帐和重置? [英] How to checkout and reset using smartgit?

查看:296
本文介绍了如何使用smartgit进行结帐和重置?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

需要帮助以了解以下内容

Need help in understanding the below

1).我该如何签出特定的提交并再次恢复为最近的提交?

1). How do i check out to a particular commit and again revert back to the recent commit ?

尝试过分支->签出->相同分支,并签出到上一个提交,但是当我这样做时,我签出的分支之后所做的提交现在丢失了!

Tried branch->checkout->same branch and check out to the previous commit, but when i did this the commits made after the one i checked out now got lost !

不在列表中签出最近的提交!

Its not in the list to checkout to recent commit !

2).我如何将头重新设置为特定提交?

2). How do i reset my head to a particular commit ?

推荐答案

(1)通常,签出不会更改分支引用,因此您可以使用签出再次切换回您的分支:只需为显示分支"选择器选择相应的分支.

(1) Usually, branch refs won't be changed by a Check Out, so you may use Check Out again to switch back to your branch: simply select the corresponding branch for "Showing Branches" selector.

如果指向您的旧标头的分支引用实际上丢失了,则可以打开日志并使用 Query | Load All Commits 显示所有此类标头,然后将临时的分支引用添加到相应的标头中并检查一下这个头.

If the branch ref to your old head is actually lost, you can open the Log and use Query|Load All Commits to display all such heads, then add a temporary branch ref to the corresponding head and check out this head.

(2)本地|重置应该适合您.

这篇关于如何使用smartgit进行结帐和重置?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆