Submodules vs. Subtrees

1
The Goal: Managing Dependencies

Your project (`Parent Repo`) needs to include code from another repository (`Library Repo`). How do you manage this relationship? Let's explore two common Git strategies.

Parent Repo

P1
P2
main

Library Repo

L1
L2
main
Key Point: You want to use the code from `Library Repo` inside `Parent Repo`, but you also want to be able to easily update the library code as it changes.