1. 程式人生 > >eclipse中svn報錯資訊的解決方案

eclipse中svn報錯資訊的解決方案

報錯資訊:

Item is out of date
svn: File '/trunk/src/main/webapp/js/cargoArrive/cargoInDest_list.js' is out of date

    Working copy is not up-to-date
svn: Commit failed (details follow):
svn: File 'F:\elc\at-lcl\src\main\webapp\js\cargoArrive\cargoInDest_list.js' is out of date
Item is out of date
svn: File '/trunk/src/main/webapp/js/cargoArrive/cargoInDest_list.js' is out of date

out of date,svn報這個錯是因為本地的資原始檔版本不是伺服器上面最新的版本,因此修改本地檔案再提交的時候,就會報Out of date錯誤。 解決辦法: 修改檔案時候一定要首先保證和伺服器一致,在做修改,具體做法 1.備份本地檔案、 2.點team–還原 3.點要提交的檔案–與資源庫同步–更新 4.把備份的檔案拷貝到要提交的檔案裡,再次提交就成功了。

報錯資訊:

delete --force F:/elc/at-lcl/target/classes/sqlxml
    Attempted to lock an already-locked dir
svn: Working copy 'F:\elc\at-lcl\target\classes' locked.
svn: 'F:\elc\at-lcl' is already locked.

svn被鎖的解決辦法: 出現svn: Working copy xxx locked 原因: SVN 本地更新時,由於一些操作中斷更新,如磁碟空間不夠,使用者取消等可能會造成本地檔案被鎖定的情況。一般出現這種情況的解決方法:  可以使用SVN clean up來清除鎖定。

  cleanup F:/elc/at-lcl

Svn版本衝突怎麼辦?

解決衝突有三種選擇:   A、放棄自己的更新,使用svn revert(回滾),然後提交。在這種方式下不需要使用svn resolved(解決),但是自己的程式碼會無法提交。   B、放棄自己的更新,使用別人的更新。使用最新獲取的版本覆蓋目標檔案,即選擇SVN中的覆蓋更新,這樣別人的檔案會覆蓋掉自己的,自己的程式碼會被沖掉。   C、手動解決:衝突發生時,通過和其他使用者溝通之後,手動更新目標檔案。然後執行resolved filename來解除衝突,最後提交。