通过电子邮件Git [英] Git over Email

查看:119
本文介绍了通过电子邮件Git的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

假设网络访问是零星的,没有中央服务器,使用git保持三个或更多分支同步的最佳方式是什么?有没有办法只提取我的deltas,发送电子邮件,并将它们合并到另一端?

虽然git格式git am是管理来自非git源的补丁的好方法,对于你应该调查git bundle的git版本库来说。

git bundle并且子命令create和unbundle可用于创建和使用增量提交的二进制blob,可用于通过替代文件传输机制跨越弱链接传输分支历史记录(例如,电子邮件,蜗牛邮件等等)。

git包将保留提交id,而format-patch / am不会导致目标提交不完全相同(不同的SHA1)。

p>

Assuming network access is sporadic with no central server, what would be the best way to use git to keep three or more branches in sync? Is there a way to extract just my deltas, email those, and merge them on the other end?

解决方案

While "git format-patch" and "git am" are great ways to manage patches from non-git sources, for git repositories you should investigate "git bundle".

"git bundle" and the subcommands "create" and "unbundle" can be used to create and use a binary blob of incremental commits that can be used to transfer branch history across a 'weak' link via an alternative file transfer mechanism (e.g. email, snail-mail, etc.).

git bundles will preserve commit ids, whereas format-patch/am will not resulting in the destination commits not being identical (different SHA1s).

这篇关于通过电子邮件Git的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆