I'm writing a web development tutorial. In it, a student starts in a git branch called 'chapter-1-start' and when she finishes the steps in that tutorial chapter, her code should look substantially the same as the code in 'chapter-1-complete.' I'd like to include 'chapter-1-complete' inside a the 'chapter-1-start' branch in a directory like 'lib/reference_app' so she can compare or, if necessary, cut and paste files from complete to start. Here are my goals:
- Keep all the code in one repository.
- Reference branch 'chapter-1-complete' inside 'chapter-1-start' should be current -- not have to update.
I think this is possible with submodules, but have no experience with them. I'm wary of losing my entire git history by putting in a recursive reference.