2015-06-03 15 views
0

我已經爲我們的一個項目創建了功能分支,並刪除了一個更改列表中的所有文檔文件。 (我知道,壞主意)。Perforce忽略集成過程中的修訂

我想一切都集成回來,除了給定的變更表,我嘗試以下忽略它:

p4 integrate //branch/[email protected],CL //main/... 
p4 resolve -at //main/... 

然而,仍然保持標記爲刪除文件 - 解決與

//main/... - no file(s) to resolver. 

是結束有什麼辦法可以告訴我們CL已經被整合了,並且在後續的整合中忽略它呢?

回答

2

注意,你至少需要2011.1服務器來做到這一點(如果你的服務器是舊的,你會得到上集成了一個錯誤消息):

p4 integrate -Rd //branch/[email protected],CL //main/... 
p4 resolve -ay 

的「-R d」標誌說,這通常會被用於d elete自動打開文件應打開集成和預定決心來代替。反過來,「p4 resolve -a y」會說你想保留我們的工作空間(一個「沒有內容改變的」整合「)的,並將其作爲最終結果提交。

提交的「集成」修訂版將記錄您已經完成了這種集成(歷史記錄將顯示「忽略」分支中已刪除的修訂版),但實際上並未更改提交文件的內容。

如果您使用「p4 merge」命令而不是「p4 integrate」命令(使用更新的服務器版本,我認爲2013.1或其附近),則所有文件都會自動解析(即包括那些先前已經爲分支或刪除而自動打開),所以使用「p4合併」時,您總是必須解決(並且可以忽略)任何源更改。

相關P4博客條目:

+0

我不知道爲什麼我錯過了'-Rd'標誌。非常感謝! – nothrow

0

看起來你想在這裏得到'resolve -ay',而不是'resolve -at'。當迴歸主體時,我認爲「他們的」是分支,而「你的」是主要的。

從「P4幫助解決」:

The resolve process is a classic three-way merge. The participating 
    files are referred to as follows: 

    'yours'  The target file open in the client workspace 
    'theirs'  The source file in the depot 
    'base'  The common ancestor; the highest revision of the 
        source file already accounted for in the target. 
    'merged'  The merged result. 

    Filenames, filetypes, and text file content can be resolved by 
    accepting 'yours', 'theirs', or 'merged'. Branching, deletion, and 
    binary file content can be resolved by accepting either 'yours' or 
    'theirs'. 
+0

布賴恩,感謝您的回答。我已經更新了我的原始問題 - 解決不會做任何事情(-ay/-at - no change) – nothrow