Build Golf (very rough post, low expectations only!)
Build Golf! Code Golf, but for Builds! Uhhh, that's sort of it.
I remember being very slightly intrigued by the concept of code golf a long time ago. But I mostly took notice of people taking it in very esoteric directions, and even before that it was pretty much orthogonal to writing the kind of useful code I care about.
But just now my brain rubbed 2 neurons together, and made the connnection to another problem that has bothered me quite often. How do you do a minimal build of some thing without some "helpful" 300 LoC boilerplate. I want like, 2 files with 3 lines each and one command to run.
Okay, there will be a couple complications to consider to avoid this going down a hacky direction like Code Golf. Like, how much tooling do you depend upon? Do you have to install a package? How many (hundred) packages does that depend upon? (Looking at you React.) But the general idea is, how to you get (for a specific task or category of tool) in a minimalist way from plain-text in git to running machine code? (or like, HTML if you're building for the web) It's a challenge of taste more than discrete optimization! If tools will reign over others in this sphere, it should be because they cater to refined tastes!
Soooo, that's my prompt. Ideas in all directions welcome. Concept for actually practically realizing this? Overly complex unworkable scoring rules? Personal fave minmal project templates? Feel free to evolve on this, or not, I'm not your boss.
1 reply
this idea is brilliant, hats off to you
i have been doing this sorta unofficially for a minute without considering it "build golf", mostly due to the fact that NPM is nightmare fuel and javascript build tooling has been out of control for a loonng time
the rules for capystack at the moment go something like
as a result, i can mostly just install nodejs pinned to a nonsloppy version and go to town; package.json can have some simple build-scripty kickstarts to run
node somescript.shor whateveri have cobbled together some non-totally-embarrassing projects this way
you can judge me for javascript, i like some other languages more (hi F#!) but they require so much hateful ecosystem that i just can't be bothered