2011-07-19 109 views
1

我有SVN自動下載一些項目從幹線的另一部分到我當前的幹線位置 - 即與SVN共享項目:外部....所有工作的工作...svn:外部接受相對路徑?

但我有硬編碼目前像這樣

MS.Utils http://192.168.1.1/svn/repro/projects/TestProj/trunk/MainApp/src/MS.Utils 

現在你可以看到這是工作,我在TRUNK目前我...當我完成這個項目,我將它移到一個分支一切都很好!因此SVN:Externals仍然會指向Trunk,可以放入相對路徑..... ???所以它會從TRUNK下載,因爲我目前在那裏,當我將它移動到一個分支或任何它將從該分支下載,因爲使用相對路徑。還有的外部屬性:

任何幫助非常感激

感謝

回答

3

正如Subversion book提到的,你可以在SVN指定相對URL。

../

Relative to the URL of the directory on which the svn:externals 

屬性設置^/

Relative to the root of the repository in which the svn:externals 

屬性版本//

Relative to the scheme of the URL of the directory on which the 

的svn:外部對象屬性設置/

Relative to the root URL of the server on which the svn:externals 

屬性版本

+0

感謝斯特凡,但現在它已經提出了我的問題。讓我解釋。我目前在我的主幹,並使用正常的相對語法(即Windows語法),這是應該工作,給你一個想法MyCompany.Utils .. \ .. \ MyCompany.SubApplication/src/MyCompany.Utils,但當然它不能用多個.. \ .. \例如...如果我使用任何其他人,它會讓我更遠離TRUNK。 – Martin

+0

這個想法是,外部工作是否在一個分支,標籤或樹幹...有2個應用程序目錄內的幹線....我需要鏈接從1到另一個使用外部....我目前有完整的路徑包括Trunk硬編碼.... – Martin