# CLAUDE.md This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository. ## Project Overview CLI tool for editing [Evolve](https://pmotschmann.github.io/Evolve/) browser game save files. Saves are LZString-compressed JSON, exported via the game's Settings > Export. ## Commands ```bash npm install # install dependencies (lz-string) # Max all capped resources, copy result to clipboard node index.js --max-resources < save.txt node index.js --max-resources "SAVE_STRING" # Print to stdout instead of clipboard node index.js --max-resources --no-copy < save.txt ``` ## Save Format Saves are LZString `compressToBase64` of a JSON object (not plain base64). Uses the `lz-string` npm package to match the game's own JS implementation. Key top-level sections: `resource`, `race`, `tech`, `city`, `space`, `civic`, `genes`, `prestige`, `settings`, `arpa`. ### Resource structure (`resource.`) - `amount`: current value - `max`: storage cap. `> 0` = capped, `-1` = unlimited (crafted), `-2` = special/uncapped, `0` = not unlocked - Other fields: `name`, `display`, `diff`, `delta`, `rate`, `bar`, `stackable`, `crates`, `containers`, `value`, `trade` ## Architecture Single-file Node.js CLI (`index.js`), one dependency (`lz-string`). Uses `pbcopy` (macOS) or `xclip` (Linux) for clipboard.