Trunk Based Development

While often hyped and misapplied, at its core, trunk-based development is about trying to optimize for the Consistency in CAP Theorem for Software Engineering. This consistency allows for team members to most rapidly and effecively work towards Developing Good Explanations.

  • VCS Hygiene:
    • Always true: No commit to master may break the build.
  • You have two options for branching strategy:
    • Easier for CI: Trunk based development.
      • Requires more discipline and tighter coordination.
      • Demands fast CI for most effective workflows.
      • Needs very small, concrete tasks. One day max per task, ideally.
      • Has different models
      • Pushing directly to master doesn’t mean it’s actually going to land; the CI can still verify it.
    • Integrates most naturally with Git-Lab: Short-lived feature branch
      • Can also be a workflow of trunk based development

references: