A Worked Example
To get a better understanding of "submodules," learn about them with the help of an example.
We'll cover the following
Maintainer
Let’s say Alice maintains a library:
1 mkdir -p lgthw_submodules
2 cd lgthw_submodules
3 mkdir alicelib
4 cd alicelib
5 git init
6 echo 'A' > file1
7 git add file1
8 git commit -am 'A'
9 git checkout -b experimental # Branch to experimental
10 echo 'C - EXPERIMENTAL' >> file1
11 git commit -am EXPERIMENTAL
12 git checkout master
13 echo 'B' >> file1
14 git commit -am 'B'