2个稳定版本
1.0.1 | 2022年7月6日 |
---|---|
1.0.0 | 2022年6月9日 |
#1415 in 文件系统
750KB
22K SLoC
目录
一个用于从git forge克隆和拉取整个组树并在磁盘上正确组织的工具。
使用方法
gtree
Sync Gitlab Trees
USAGE:
gtree <SUBCOMMAND> [SCOPE]
ARGS:
<SCOPE> Only operate on this subtree
OPTIONS:
-h, --help Print help information
-j, --jobs <JOBS> Number of jobs to run in parallel, 0 is automatic [default: 0]
SUBCOMMANDS:
help Print this message or the help of the given subcommand(s)
list List Directories
sync Download new repositories and delete old ones, also update
update Pull and Push new commits to and from the cloned repos
配置
配置文件的默认位置是 $HOME/.config/gtree/config.toml
,格式为toml,也支持yaml。
# Give the forge a easily identifiable name
["gitlab.com"]
# Configure which kind of forge this is
# Currently only gitlab is supported
type = "gitlab"
# Set the domain name to reach the forge at
host = "gitlab.com"
# API Token for the forge
# for gitlab this is a Personal Access Token
# https://gitlab.com/-/profile/personal_access_tokens
token = "HgDAfJ9tfD5xUw2L6SUm"
# Directory to clone the repos into
directory = "/home/audron/repo/gitlab.com"
依赖关系
~25–37MB
~664K SLoC