← knowledge.oriz.in

Submodule pattern — each site/package/extension is a separate GitHub repo

architecture architecturegitsubmodulesrepoworkflow

Submodule pattern — each site/package/extension is a separate GitHub repo

Concept

The family is structured as one master repo (chirag127/oriz) plus many independent GitHub repos (one per site, package, extension). The master repo references each child repo as a git submodule, storing a SHA pointer. Each child has its own issues, releases, CI, and main branch.

How it works

Why this shape

Three properties matter:

  1. Each site / package / extension can be released independently. A bug fix to oriz-blog doesn't need a master commit; the master commit happens when production should pin to that fix.
  2. Open-source visibility per repo. Recruiters read chirag127/blog-site directly, with its own README, issues, and stars.
  3. Per-repo CI keeps blast radius small. A failing extension build blocks only that extension's release, not the family.

The cost is workflow complexity: a change spans two commits (child + master pointer bump). The rule "no push without say-so" applies at every level, which keeps the workflow tractable even with many moving submodules.

Cross-refs