如何在不改变 Perforce 中的工作树的情况下清除默认更改列表 [英] How do you clear the default changelist without altering your worktree in Perforce

查看:40
本文介绍了如何在不改变 Perforce 中的工作树的情况下清除默认更改列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

偶然地,我调和了我所有的工作.我现在想保持我的工作树原样,但必须强制从默认更改列表中删除更改.如何在不影响文件的情况下清除默认挂起的更改列表?我不想恢复到仓库状态.

By accident I reconciled all my work. I want to now keep my working tree as it is, but have perforce remove the changes from the default changelist. How do you clear the default pending changelist without affecting the files? I do not want to revert to the depot state.

推荐答案

p4 revert -k //...

请注意,这有点危险,因为现在您有 Perforce 不知道的本地更改——当您提交时,它们会被悄悄遗漏(除非您再次进行协调),并且强制同步可能会覆盖它们.如果您更改的文件处于打开状态,Perforce 可以更智能地了解您对它们进行的更改——当它们在库中更改时安排解决,同步时注意不要修改它们,等等.

Note that this is a little dangerous because now you have local changes that Perforce doesn't know about -- they'll be silently missed when you submit (unless you do another reconcile), and a force sync may overwrite them. If your changed files are open, Perforce can be a lot more intelligent about the fact that you've made changes to them -- schedule resolves when they change in the depot, be careful not to modify them when syncing, etc.

这篇关于如何在不改变 Perforce 中的工作树的情况下清除默认更改列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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