資源描述:
《工作區(qū)導(dǎo)入git倉(cāng)庫(kù)操作步驟》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在工程資料-天天文庫(kù)。
1、工作區(qū)導(dǎo)入git倉(cāng)庫(kù)操作步驟(開發(fā)人員)1?生成ssh密鑰對(duì)著空白處右鍵,選擇gitbashhere,彈出git客戶端命令窗口。1??設(shè)置上傳人員賬號(hào)和郵箱設(shè)置全局賬號(hào)gitconfig?-globaluser.name"liny"設(shè)置全局郵箱gitconfig-globaluser.email"liny@github.com〃2?生成ssh密鑰ssh?keygen?trsa?C"inv@github.com〃修改為你的郵箱,之后會(huì)耍求確認(rèn)路徑和輸入密碼,默認(rèn)的一路回車就行。1?默認(rèn)生成路徑在用戶目錄?ssh下,如:C:Usersliny2.rsa是私鑰,id_rsa.pub是
2、公鑰,打開id_rsa.pub,復(fù)制里面的key給git服務(wù)器管理員,在倉(cāng)庫(kù)服易上進(jìn)行配置,過(guò)ssh驗(yàn)證通信,否則連接不了git服務(wù)器。注意:window客戶端輸入git命令出錯(cuò)。打開windows的cmd,輸入git提示"不是內(nèi)部或外部命令,也不是可運(yùn)行的程序”,在我的電腦環(huán)境變量path添加git安裝路徑,例如:C:ProgramFilesGitbino2?開發(fā)工具配置ssh打開sts開發(fā)工具,window-preferences,選擇密鑰生成的路徑,搜索ssh,并將私人密鑰添加進(jìn)來(lái)。3?建立工作區(qū)1?從遠(yuǎn)程倉(cāng)庫(kù)克隆工作區(qū),右鍵選擇importoSpring?Spring
3、ToolSuite?竺出GDU□、?€川cEditSourceRefactorNavigateSearchProjectRunWindowHepT?半PackageExplorer6ServersMServers口OBootOwMbbord口□OConsole話i*」d?:e-=Noconsolestodisplayatthistime.New■ShowInAlt+Shift+W?CopyCtd^CCopyQualifiedNamePPasteCtd>V11[匕Import-RefreshF5WvotditcServerDeveloperEd百onv3.1;S*ppr-2?選擇gi
4、t~Projectsfromgit3?選擇cloneURISelectRepositorySourceSelectalocationofGitRepositoriesl嚴(yán)Back」Next>FinishCancel4.URI填寫要克隆的遠(yuǎn)程倉(cāng)庫(kù)的地址:ssh://git@192.16&31.206:22/homc/git/dcmoSito.gitSourceGitRepositoryEnterthelocationofthesourcerepository.Host:192.168.31.206Repositorypath:/home/git/demoSite.gitConnect
5、!onProtocol:ssh22Port:5?如果在生成密鑰路徑下?ssh沒(méi)有known_hosts文件,則會(huì)彈出如下窗口,選擇yesBranchSelectionSelectbranchestoclonefromremoterepository.RemotetrackingbrancheswillbecreatedtotrackupdatesforthesebranchesintheremoteBranchesofssh://git@192.168.31.206:22/home/git/rnyproject.git:QuestionTheauthenticityofhost*1
6、92.168.31.206*can'tbeestablished.RSAkeyfingerprintis23:2f:c5:fd:0f:87:dl:c9:22:2b:04:40:2a:el:72:66.Areyousureyouwanttocontinueconnecting?SelectAllDeselectAllINoCancelGettingremotebranchesinformation凰7、fromremoterepository.RemotetrackingbrancheswillbecreatedtotrackupdatesforthesebranchesintheBranchesofssh://git@192.168.31.206:22/home/git/myproject:typefiltertext~n^'HEADj:*N為develop□masterSelectAllDeselectAllFinishCancel7?選擇工