最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

Undo multiple changes in perforce leaving changes in between - Stack Overflow

programmeradmin3浏览0评论

How do we undo multiple changelists in Perforce GUI? If I want to undo 101 and 106 and nothing in between ? I do not see that option anywhere in the GUI. If I try to do that, the message says that the file is already checked out and cannot perform Undo. This get complex as 101 and 106 contains some same file and some different files

Tried using the all there options given in the link. But could not find an option to remove only some of them in a range

For a range of change lists I found the following. How do I undo several change lists in Perforce relating to the same files without submitting each one?

How do we undo multiple changelists in Perforce GUI? If I want to undo 101 and 106 and nothing in between ? I do not see that option anywhere in the GUI. If I try to do that, the message says that the file is already checked out and cannot perform Undo. This get complex as 101 and 106 contains some same file and some different files

Tried using the all there options given in the link. But could not find an option to remove only some of them in a range

For a range of change lists I found the following. How do I undo several change lists in Perforce relating to the same files without submitting each one?

Share Improve this question asked Jan 19 at 16:39 Logic WandererLogic Wanderer 1
Add a comment  | 

1 Answer 1

Reset to default 1

Undo one change, submit, then undo the other.

The p4 undo command doesn't support undoing changes to a file that's already open; this is largely because the first part of the undo operation involves rolling back the workspace file and discarding any later changes, and it's not possible to do that while also preserving any other changes that might have been made in the workspace (such as undoing some other change).

You could attempt to script your own version of undo that follows a different strategy (this is doable and possibly even entertaining, but you'd need to be pretty adept with 3-way merging and Perforce semantics to implement it correctly, and even speccing it out is beyond the scope of a stackoverflow answer).

Best option is to submit in between the undo operations, since this gives you a "safe" (i.e. submitted) basis for applying the second undo.

发布评论

评论列表(0)

  1. 暂无评论