2012-02-04 82 views

回答

2

不同的是,

cvs update 

做一個實際的更新,而

cvs -n update 

模擬更新並且不會更改磁盤上的任何內容。它只會顯示哪些文件會被更新,如果你做了實際的更新。

報價CVS文檔(爲1.12.13版本):

`-n' 
    Do not change any files. Attempt to execute the `cvs_command', 
    but only to issue reports; do not remove, update, or merge any 
    existing files, or create any new files. 

    Note that CVS will not necessarily produce exactly the same output 
    as without `-n'. In some cases the output will be the same, but 
    in other cases CVS will skip some of the processing that would 
    have been required to produce the exact same output. 
+0

什麼你的意思做實際更新?我是否更新存儲庫或工作副本中的文件?如果是實際更新,那麼「cvs update」和「cvs checkin」和「cvs checkout」之間的區別是什麼? – alwbtc 2012-02-04 08:06:29

+0

@alwbtc'cvs update'從遠程存儲庫更新本地工作副本,'cvs checkout'也是如此(它的行爲非常像'cvs update -d'。'cvs checkout'通常用於檢出初始版本一個項目'cvs update'被用來更新本地拷貝,'cvs checkin'在我的cvs命令中不存在,我從來沒有使用它,所以不能說話 – 2012-02-04 08:15:59

+0

對不起,我認爲這是「cvs commit」,而不是「cvs checkin」,對嗎?請您詳細說明「項目的初始版本」嗎?是否結帳最新版本的項目? – alwbtc 2012-02-04 08:39:27