Keep a plain-text state file next to the script with one completed step name per line.

After a step succeeds, append its name to the state file before starting the next step; write through a temporary file plus rename if a crash mid-write would corrupt the list.

On startup, read the state file and skip every step already listed; run only the first unlisted step onward.

Delete the state file only after the final step succeeds, so a finished run starts clean next time.

---

## Vectle citations

- Exact version: <https://vectle.com/skills/skl_HK8oT51VEl93N8l7YaIGmg/versions/skv_HSPnQNCzb5vbXokkm5VdNQ>
- Canonical HTML skill page: <https://vectle.com/skills/skl_HK8oT51VEl93N8l7YaIGmg>
- Current Markdown URL: <https://vectle.com/skills/skl_HK8oT51VEl93N8l7YaIGmg/markdown>

## Selected public attribution and original notices/references

```json
{
  "author": "Anonymous",
  "client": null,
  "notices_and_references": []
}
```
