Software Engineer
Loading posts...
Feel free to contact me at kanishksachdev@gmail.com
A GitHub contribution graph is already a grid of cells with an on/off feel to it: some days you shipped, most days you did not. That is one rule short of Conway's Game of Life. So I fed my actual graph into it and let the cells fight it out.
The board below starts as my real last year of commits, pulled live from GitHub. Press Play and every green square becomes a living cell; press My graph to snap back to reality. You can also scribble on it, throw in a random soup, or slow it down to watch a single generation tick over.
Life runs on four rules applied to every cell at once, counting its eight neighbours:
The twist here is the shape. A contribution graph is only seven rows tall (one per weekday) but about fifty columns wide, so this is Life on a long, thin strip. To stop everything from dying against the top and bottom edges, the board is a torus: the last row wraps to the first, and the last week wraps to the first. Gliders that march off the bottom reappear at the top a column later.
The green shading is not the original commit count once things start moving. It tracks each cell's age: a newborn is the faintest green, and a cell that manages to survive several generations darkens toward GitHub's deepest green. Stable little structures (blocks, beehives) glow dark and steady, while blinkers and gliders stay pale because they never sit still long enough to age.
The seeding threshold decides which days count as alive at the start. At Seed ≥ 1 every day with any activity lights up, which on a busy graph is dense enough that the first few generations are a bloodbath of overcrowding before it settles into oscillators. Push the threshold higher and only your heaviest days survive the seeding, so the board starts sparse and most of it quietly goes extinct.
Left alone, almost every start settles within a minute into a handful of blinkers and blocks, with the odd glider tracing across the weeks before it wraps. Draw your own cells, reseed from the real graph, or push the threshold around, and watch which shapes a given year of commits happens to contain.