1 Star 4 Fork 1

jacobwang/git-training-supplement

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
sourcetree-login-without-account-on-windows.md 1.80 KB
一键复制 编辑 原始数据 按行查看 历史
jacobwang 提交于 2017-05-12 16:15 . rename file

前言

本文档仅适用于 windows 平台

问题

安装 SourceTree 过程,会被强制登录,否则不能使用。但是由于特殊的网络环境,正常情况下,注册 SourceTree 或使用 G+ 账号,会变得异常困难,因此我们需要优雅跳过登录授权操作。

sourcetree-login

解决方案

  • 进入用户本地文件夹下的 SourceTree 目录 %LocalAppData%
  • 新建目录结构 Atlassian/SourceTree (系统自动创建目录,则跳过此步骤)
  • 新建 accounts.json 文件

LocalAppData

地址栏输入 %LocalAppData%,回车后跳转用户本地的 Local 目录

sourcetree-accounts-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,直接显示主窗口

参考资料:

SourceTree 免登录跳过初始设置

马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/jacob-lab/git-training-supplement.git
git@gitee.com:jacob-lab/git-training-supplement.git
jacob-lab
git-training-supplement
git-training-supplement
master

搜索帮助

Cb406eda 1850385 E526c682 1850385