Wish it supported rollbacks..
replies(1):
Add a PostToolUse [0] hook that automatically creates a git commit whenever changes are made. Then you can either git checkout the commit you want to rollback to... Or you could assign those git commits an index and make a little MCP server that allows you to /rollback:goto 3 or /rollback:back 2 or whichever syntax you want to support.
In fact if you put that paragraph into Claude I wouldn't be surprised if it made it for you.
[0] https://docs.anthropic.com/en/docs/claude-code/hooks#posttoo...