When to use git subtree?

后端 未结 5 660
孤街浪徒
孤街浪徒 2020-11-30 20:22

What problem does git subtree solve? When and why should I use that feature?

I\'ve read that it is used for repository separation. But why would I not j

5条回答
  •  长情又很酷
    2020-11-30 20:56

    To add to above answers, an additional drawback of using subtree is the repo size compared to submodules.

    I don't have any real world metrics, but given that each time a push is made on a module, everywhere that module is used gets a copy of the same change on the parent module (when is subsequently updated on those repos).

    So if a code base is heavily modularised, that will add up quite quickly.

    However, given storage prices are always coming down, that may not be a significant factor.

提交回复
热议问题