1. 程式人生 > >source跳過註冊使用

source跳過註冊使用

當前只有Win的版本,Mac自行百度(笑)

很多人用git命令列不熟練,那麼可以嘗試使用sourcetree進行操作。

然鵝~~sourcetree又一個比較嚴肅的問題就是,很多人不會跳過註冊或者操作註冊。

廢話不多,我們直接開始跳過註冊階段的操作。

下載好之後會有這麼一個介面要求你註冊或登入。(不管它)將下面的一串串放進我的電腦的位址列,開啟sourcetree的資料夾

%LocalAppData%\Atlassian\SourceTree\

通常長這樣

對,沒錯,你會看到一個很不和諧的檔案你是沒有的

恩,就是它,所以接下來你應該在當前資料夾下建立一個json檔案,檔名為accounts.json

(如果不知道如何檢視被隱藏掉的字尾名,請自行百度)

然後,編輯此檔案的內容如下

複製程式碼

[
  {
    "$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
  }
]

複製程式碼

儲存此檔案。

 重新啟動sourcetree,恩,噠~噠噠~~~