Skip to content İçeriğe geç

Why my build scripts are boring Derleme betiklerim neden sıkıcı

Every project I start now gets the same three files before it gets a name: a Makefile, a lockfile, and a test that fails. It is not a ritual. It is the cheapest insurance I know of against the version of me who shows up at 23:40 convinced that a quick fix does not need a check.

Boring output ages well

The build script is deliberately boring. No colors, no spinners, no summary banner. It prints what it ran and whether it passed, then exits. Boring output is easy to read in a log six months later, and six months later is when I actually need it.

A tool you stop noticing is a tool that is working.

Makefile

The whole thing is short enough to paste here. Three commands, three lines of output.

$ make check
ruff .          ok
pytest -q       142 passed
mypy src        ok

When a line is not ok

When any of them says something other than ok, the commit does not happen.

The boring path

None of this is novel. That is the argument. The boring path has been walked by enough people that the potholes are marked.

Artık başladığım her proje isim almadan önce aynı üç dosyayı alıyor: bir Makefile, bir lockfile ve başarısız olan bir test. Bu bir ritüel değil.

Sıkıcı çıktı iyi yaşlanır

Derleme betiği bilerek sıkıcı. Renk yok, dönen simge yok, özet başlığı yok. Ne çalıştırdığını ve geçip geçmediğini yazar, çıkar.

Fark etmeyi bıraktığın araç, çalışan araçtır.

Makefile

Hepsi buraya yapıştırılacak kadar kısa. Üç komut, üç satır çıktı.

$ make check
ruff .          ok
pytest -q       142 passed
mypy src        ok

Bir satır ok demediğinde

Herhangi biri ok dışında bir şey söylerse commit olmaz.

Sıkıcı yol

Bunların hiçbiri yeni değil. Sav da bu. Sıkıcı yol yeterince kişi tarafından yüründü; çukurlar işaretli.

Command palette Komut paleti