http://www.perforce.com/documentation/perforce_technical_documentation
http://blog.csdn.net/brucexu1978/article/details/7181768
http://www.perforce.com/perforce/doc.current/manuals/cmdref/sync.html
P4遞交建議流程:
1. p4 sync
2. 覆蓋或者改動local文件
3. p4 delete or 直接delete 廢棄的文件
4. p4 add: 增加新文件到depot
5. p4 diff -se: 查看編輯過的文件
6. p4 diff -se | p4 -x - edit: 把所有改動過的文件置為open for submit,對於覆蓋的文件 or沒有用p4 edit的文件,需要這個命令, 才能將文件置為open狀態, 才能方便遞交
7. p4 diff -sd: 查看刪除的文件(未用p4 delete刪除的)
8. p4 diff -sd | p4 -x - delete: 置刪除的文件為opened狀態, 方便遞交
9. p4 submit -d 'xxx': 遞交
P4可以差分遞交, 只要別人的遞交沒有影響到你的遞交, 任何時候都可遞交, 這一點, 和svn相同, 和git不同。
恢復:
p4 revert -a (file 可選): revert所有打開的已經存在的文件