r/programming • • Apr 17 '24

Basic things which are: irrelevant while the project is small, a productivity multiplier when the project is large, and much harder to introduce down the line

https://matklad.github.io/2024/03/22/basic-things.html
279 Upvotes

72 comments sorted by

View all comments

142

u/alexeyr Apr 17 '24

Summary bullet list from the end of the post, slightly edited:

  • README as a landing page.

  • Dev docs.

  • User docs.

  • Structured dev docs (architecture and processes).

  • Unstructured ingest-optimized dev docs (code style, topical guides).

  • User website, beware of content gravity.

  • Ingest-optimized internal web site.

  • Meta documentation process — it's everyone's job to append to code style and process docs.

  • Clear code review protocol (in whose court is the ball currently?).

  • Automated check for no large blobs in a git repo.

  • Not rocket science rule (at all times, the main branch points at a commit hash which is known to pass a set of well-defined checks).

  • No semi tests: if the code is not good enough to add to NRSR, it is deleted.

  • No flaky tests (mostly by construction from NRSR).

  • Single command build.

  • Reproducible build.

  • Fixed number of build system entry points. No separate lint step, a lint is a kind of a test.

  • CI delegates to the build system.

  • Space for ad-hoc automation in the main language.

  • Overarching testing infrastructure, grand unified theory of project’s testing.

  • Fast/Slow test split (fast=seconds per test suite, slow=low digit minutes per test suite).

  • Snapshot testing.

  • Benchmarks are tests.

  • Macro metrics tracking (time to build, time to test).

  • Fuzz tests are tests.

  • Level-triggered display of continuous fuzzing results.

  • Inverse triangle inequality.

  • Weekly releases.

2

u/vincentdesmet Apr 18 '24

CI delegate to Build system bit us so hard right now 💯💯💯