A parent repository that acts as a directory of projects. The landing page
(index.html) is an index of everything in the portfolio, and each project is
pulled in as a git submodule under projects/. The parent repo owns the
index; each project keeps its own independent history, and the parent simply
records which commit of each project it is currently pointing at.
- One front door.
index.htmlgives a client (or a team) a single page that links out to every project. - Independent projects. Each project lives in its own repository with its own issues, branches, and release history. Work continues there normally.
- Reviewed updates. The parent only advances a project's pointer when someone deliberately updates the submodule and commits that change. New work in a project does not silently change the parent — you pull it in when it has been reviewed and you're ready.
WorkFlowTest-Main/
├── README.md ← this file
├── index.html ← the directory / landing page
├── .gitmodules ← declares each submodule and its remote URL
└── projects/
├── submod-one/ ← submodule → MitosisCreative/WorkFlowTest-Submod-One
└── submod-two/ ← submodule → MitosisCreative/WorkFlowTest-Submod-Two
.gitmodules records the remote URL and path for each project. The parent's own
git history stores a gitlink — a pinned commit SHA — for each submodule, so a
clone always reproduces the exact project versions this directory was built
against.
A normal git clone leaves the projects/* folders empty — submodules are opt-in.
Clone recursively:
git clone --recurse-submodules git@github.com:MitosisCreative/WorkFlowTest-Main.gitAlready cloned without --recurse-submodules? Populate them after the fact:
git submodule update --init --recursivegit submodule add git@github.com:MitosisCreative/<Project>.git projects/<project>
git add .gitmodules projects/<project>
git commit -m "Add <project> to the directory"Then add a matching entry to index.html.
When a project has new work you want the directory to point at:
cd projects/submod-one
git checkout main
git pull # get the latest reviewed commit
cd ../..
git add projects/submod-one # record the new pointer in the parent
git commit -m "Update submod-one to latest reviewed commit"The parent now points at the newer commit. Nothing changed until you ran
git add on the submodule and committed — that's the review gate.
git submodule update --remote --merge
git add projects
git commit -m "Update projects to latest reviewed commits"--remote moves each submodule to the tip of its tracked branch (main). Review
the diff before committing.
A submodule is a full checkout. Make changes, commit, and push from inside it — that history belongs to the project's own repository:
cd projects/submod-one
git checkout main
# ...edit, commit...
git pushThen return to the parent and record the new pointer (the git add + commit step
above) whenever you want the directory to reflect that work.
git submodule statuslists each project and the exact commit the directory pins. A leading+means the checked-out commit differs from the pinned one; a-means the submodule isn't initialized yet.- Deleting a project:
git submodule deinit -f projects/<project>, remove its entry from.gitmodules, thengit rm projects/<project>.