【发布时间】:2016-05-25 23:21:49
【问题描述】:
他们说
git-subtree 存储子项目提交 ID,而不是元数据中的引用。
意思是命令
git subtree add --prefix some-split-sub-directory https://some-other-repo-url master --squash
将主 HEAD 的 SHA-1 存储在 git 管理的元数据信息中的某个位置 https://some-other-repo-url。
现在当我下次运行以下命令时
git subtree pull --prefix some-split-sub-directory https://some-other-repo-url master --squash
git 知道 URL https://some-other-repo-url 上最后一次提交的 SHA-1,它已合并到根/父项目中,现在它会获取/合并最后一次提交 SHA-1 之外的代码/提交。
现在我的问题是,last-commit-of-subtree 的信息存储在本地 .git 文件夹中的什么位置?
我怎么能看到这是针对这个 repo 存储的最后一次提交 SHA-1 并且高于/超出下一次拉/合并将发生?
我曾窥视过以下地方,例如 .git/config、.git/refs,但没有找到任何信息。
【问题讨论】:
标签: git git-subtree