這里主要是想把selenium的整個(gè)項(xiàng)目同步到eclipse的經(jīng)歷分享一下。雖然有時(shí)候想想沒有必要,因?yàn)槟阆螺d的包里本身就包含了源代碼榄鉴,但是我就是這樣做了。
selenium項(xiàng)目地址: (只讀)
方法一渡贾、直接使用TortoiseSVN
1逗宜、安裝TortoiseSVN。下載地址:http://tortoisesvn.net/downloads
2空骚、在eclipse的Workspace目錄下直接新建一個(gè)文件夾纺讲,右擊文件夾 -> TortoiseSVN《谝佟-> Export... ,在打開的彈層"URL of repository:"下面的輸入框輸入http://selenium.googlecode.com/svn/trunk/,點(diǎn)擊OK熬甚。
3、把同步下來文件夾做為一個(gè)項(xiàng)目導(dǎo)入eclipse肋坚。(File>>Import>>General>>Existing Projects into Workspace 然后選擇自己的項(xiàng)目)
方法二乡括、使用Subclipse
Subclipse是一個(gè)eclipse插件。(包括 Eclipse PDT和 Zend Studio for Eclipse).它能在eclipse里面安裝和更新智厌。
subclipse安裝步驟(比較懶诲泌,直接復(fù)制官網(wǎng)的):
? Go to Help | Software Updates | Find and Install...
? Choose Search new features to install, Next.
? Choose New Remote Site, enter name "Subclipse" and URL "http://subclipse.tigris.org/update_1.8.x".
? Select the created "Subclipse" site and click Next.
? Follow the instructions and restart the workbench.
安裝好了之后,重啟eclipse铣鹏,切換eclipse到SVN資源庫
? 在eclipse工具欄敷扫,Window | open perspective | Other...
? 選擇 "SVN 資源庫研究,OK
? 在進(jìn)入"SVN資源庫"后诚卸,右擊—>新建->資源庫位置...
? 在彈出的層中輸入 http://selenium.googlecode.com/svn/trunk/葵第,F(xiàn)inish.
? 這樣會(huì)在左邊的面板出現(xiàn)這個(gè)添加的庫绘迁,直接右擊->檢出為...
? 在彈出的框中隨便輸入項(xiàng)目名,F(xiàn)inish卒密。
ok了缀台,得到的項(xiàng)目和上圖一樣。
PS:有時(shí)候?qū)С龅捻?xiàng)目會(huì)有報(bào)錯(cuò)栅受,主要是第三方包有更新将硝,看一下Path下的jar文件是不是有missing的情況。