Scalar C# 实现的巨型 Git 仓库管理工具

程序名称:Scalar

授权协议: MIT

操作系统: Windows

开发语言: Objective-C

Scalar 介绍

Scalar 是一个使用 C# 编写的 .NET Core 应用程序, 支持在 Windows 和 macOS 平台中运行 。Scalar
通过设置所建议的配置值和运行后台维护来最大程度优化 Git 命令的性能。无论开发者使用什么服务来托管代码仓库,Scalar 都能有效地加速 Git 指令。

微软表示,只要使用 Scalar 为体积最大的代码仓库进行注册,就能马上感受到 Git 执行速度大的幅提升。

Scalar 目前使用稀疏检出而非虚拟文件系统,因此在执行 Git 命令时会存在瓶颈,特别是git checkout 的速度不及 VFS for
Git,微软正在研究并行版本的git checkout,以提高执行性能

使用示例

使用以下命令克隆测试仓库并初始化一些稀疏内容,在 macOS
Terminal 或 Windows 的 Git Bash 中运行这些命令。

$ scalar clone https://dev.azure.com/gvfs/ci/_git/ForTests
Clone parameters:
  Repo URL:     https://dev.azure.com/gvfs/ci/_git/ForTests
  Branch:       Default
  Cache Server: Default
  Local Cache:  C:\.scalarCache
  Destination:  C:\_git\ForTests
  FullClone:     False
Authenticating...Succeeded
Querying remote for config...Succeeded
Using cache server: None (https://dev.azure.com/gvfs/ci/_git/ForTests)
cloning...Succeeded
Fetching commits and trees from origin (no cache server)...Succeeded
Configuring Watchman...Succeeded.
Validating repo...Succeeded

$ cd ForTests/src
$ ls
AuthoringTests.md  GvFlt_EULA.md  GVFS.sln  License.md  nuget.config  Protocol.md  Readme.md  Settings.Stylecop

$ git sparse-checkout set GVFS/GVFS.Common GVFS/GVFS.UnitTests GitHooksLoader
$ ls
AuthoringTests.md  GitHooksLoader/  GvFlt_EULA.md  GVFS/  GVFS.sln  License.md  nuget.config  Protocol.md  Readme.md  Settings.Stylecop

$ ls GVFS
GVFS.Common/  GVFS.UnitTests/  LibGit2Sharp.NativeBinaries.props  ProjectedFSLib.NativeBinaries.props

$ git sparse-checkout set GVFS/GVFS GVFS/GVFS.Common GVFS/GVFS.UnitTests GitHooksLoader
$ ls GVFS
GVFS/  GVFS.Common/  GVFS.UnitTests/  LibGit2Sharp.NativeBinaries.props  ProjectedFSLib.NativeBinaries.props

Scalar 官网

https://github.com/microsoft/scalar/

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 [email protected] 举报,一经查实,本站将立刻删除。

相关推荐