1.首先下載並安裝好git程序。html
2.接着下載並執行SourceTreeSetup-3.1.3.exe,會進入登陸或註冊bitbucket的界面,我只是想用軟件,並不想去註冊帳號。怎麼辦?請往下看。git
3.json
打開 %LocalAppData%\Atlassian目錄,接着進入SourceTree目錄,建立accounts.json文件,並修改accounts.json內容以下:spa
[3d
{code
"$id": "1",htm
"$type": "SourceTree.Api.Host.Identity.Model.IdentityAccount, SourceTree.Api.Host.Identity",blog
"Authenticate": true,get
"HostInstance": {it
"$id": "2",
"$type": "SourceTree.Host.Atlassianaccount.AtlassianAccountInstance, SourceTree.Host.AtlassianAccount",
"Host": {
"$id": "3",
"$type": "SourceTree.Host.Atlassianaccount.AtlassianAccountHost, SourceTree.Host.AtlassianAccount",
"Id": "atlassian account"
},
"BaseUrl": "https://id.atlassian.com/"
},
"Credentials": {
"$id": "4",
"$type": "SourceTree.Model.BasicAuthCredentials, SourceTree.Api.Account",
"Username": "",
"Email": null
},
"IsDefault": false
}
]
4.
打開 %LocalAppData%\Atlassian,進入「SourceTree.exe_Url_iayhtc13zv3obzuz5vchezjs1az2q5ef」(注該目錄可能和版本相關,不一樣版本的路徑可能不徹底同樣。)
接着進入"3.1.3.3158"目錄,打開user.config文件,在裏面加入六行代碼。
<setting name="AgreedToEULA" serializeAs="String"> <value>True</value> </setting> <setting name="AgreedToEULAVersion" serializeAs="String"> <value>20160201</value> </setting>
5
再次執行SourceTreeSetup-3.1.3.exe,此處可能會出現以下二種狀況,
狀況一就進入下一步安裝。
第二種狀況
選擇第四個
6。完成安裝,過程跳過繁瑣的bitbucket註冊。 :)
搞定。
本文參考地址:https://jingyan.baidu.com/article/4f34706e6e4985e386b56d79.html 百度經驗