Perforce - 删除每个给定更改列表范围的增量 [英] Perforce - removing delta per given changelist range

查看:63
本文介绍了Perforce - 删除每个给定更改列表范围的增量的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个大背景的小问题.让我问一个简短的版本,然后再扩展一点.

I got a small question with a big background. Let me ask a short version and then expand it a little bit.

我的问题的简短版本如下.

Short version of my question is as follows.

想象一种情况——你有一个分支 A,其中的变更列表从 1000 到 1004.然后你从变更列表 1004 创建分支 B 并添加更多的修订(1005、1006).之后,您需要从分支 B 中删除由变更列表 1002 引入的增量.我该怎么做?如果我在分支 A 上需要它 - 没问题,只需回滚到 1001 并重新集成 1003-1004.但是我需要删除由分支上的变更列表引入的增量,该分支的历史记录中没有此变更列表.那么我该如何进行这种选择性删除"呢?

Imagine a situation - you have branch A with changelists 1000 to 1004. Then you make branch B from changelist 1004 and add a couple of more revisions (1005, 1006). After that you need to remove delta introduced by changelist 1002 from branch B. How can I do it? If I needed that on branch A - no problem, just Rollback to 1001 and re-integrate 1003-1004. But I need to remove a delta that was introduced by a changelist on a branch that does not have this changelist in its history. So how can I do this "selective delete"?

我的问题的歌词背景如下.回到过去,当我还是 ClearCase 工程师时,我有时会使用一种称为减法合并"的功能.我调用了合并"命令,指出了 2 个版本来标识一个增量和一个表示删除"之类的标志(这是几年前,我忘记了确切的标志).它所做的是它删除了尖角增量,无论该增量何时实际引入 - 1 次提交或一年前.所以这是一个减法合并,可以在不删除任何版本的情况下用作回滚,有点切掉"了一些增量.

The lyric background of my question is as follows. Back in the old days when I was a ClearCase engineer, I sometimes used a feature called 'subtractive merge'. I called "merge" command, pointed 2 versions to identify a delta and a flag that said something like "remove" (this was a few years ago, I forgot the exact flag). What it did is that it removed the pointed delta regardless of when that delta was actually introduced - 1 commit away or a year ago. So it's a subtractive merge that might be used as a rollback without deleting any versions, kinda "cut away" some delta.

现在我使用 Perforce,我可以看到回滚"命令,该命令允许创建一个更改列表,将现在"中的增量删除回我指定的更改列表.这就是 Perforce 知识库建议您在需要删除某些增量时执行的操作.如果您需要删除一系列更改列表,您需要将整个更改列表的堆栈从现在"回滚到前任更改列表,然后整合回除您想丢弃的更改列表之外的所有内容.所以 - 删除 N 个变更列表,然后整合回 N-1 个变更列表.我不知道......这对我来说似乎是一个开销.

Now I use Perforce and I can see "Rollback" command that allows make a changelist that removes a delta from "now" back to a changelist that I specify. And that's how Perforce knowledge base advises to do when you need to remove some delta. And if you need to remove a range of changelists, you need to rollback that whole changelists' stack from "now" back to the predecessor changelist and then integrate back everything except for the changelist you wanted to throw away. So - remove N changelists, and then integrate back N-1 changelist. I don't know... That is looks like an overhead for me.

请问有经验的Perforce用户,你知道如何在Perforce中进行减法整合"吗?

So I ask experiences Perforce users, do you know how to do "subtractive integrate" in Perforce?

提前致谢.

推荐答案

似乎我错过了就在我眼前的关键 Perforce 功能......Back Out Submitted Changelist #####"是正确的事物.请参阅 回滚"之间的区别是什么..."和退出提交的变更列表#####";在 Perforce P4V 中

Seems like I missed the key Perforce feature which was right in front of my eyes... "Back Out Submitted Changelist #####" does the right thing. See What is the difference between "Rollback..." and "Back Out Submitted Changelist #####" in Perforce P4V

这篇关于Perforce - 删除每个给定更改列表范围的增量的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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