轉自:http://www.cnblogs.com/xiofee/p/sourcetree_pass_initialization_setup.htmlhtml
在SourceTree的配置目錄新建(或修改)accounts.json爲以下內容。配置目錄通常位於:C:\Users\Administrator\AppData\Local\Atlassian\SourceTree,該目錄需先啓動一次SourceTree纔會被生成(通常安裝完SourceTree後,運行下,提示登陸時就能夠退出了,此時配置目錄已經被生成)!json
accounts.json:ssh
[ { "$id": "1", "$type": "SourceTree.Api.Host.Identity.Model.IdentityAccount, SourceTree.Api.Host.Identity", "Authenticate": true, "HostInstance": { "$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 } ]
-------特別說明下-------spa
要想ssh私鑰和Linux下的通用,要將SourceTree通常選項下的SSH Client類型改成OpenSSH。 htm