# Checkpointing (Beta)

> ⚠️ **Beta Feature**: Checkpointing is currently in Beta and features may change.

## Overview

Automatically track and rewind CodeBuddy edits to quickly restore unwanted changes.

CodeBuddy Code automatically tracks CodeBuddy's edits to files as you work, allowing you to quickly undo changes and revert to a previous state if something goes wrong.


## Common Use Cases

Checkpointing is particularly useful in these scenarios:

- **Exploring Alternatives**: Try different implementation approaches without losing your starting point
- **Recovering from Errors**: Quickly undo changes that introduced bugs or broke functionality
- **Feature Iteration**: Confidently experiment knowing you can always restore to a working state

---

## Limitations

### Changes via Bash Commands Are Not Tracked

Checkpointing does not track files modified through bash commands. For example, if CodeBuddy Code runs:

```
rm file.txt
mv old.txt new.txt
cp source.txt dest.txt
```

These file modifications cannot be undone via the rewind feature. Only edits made directly through CodeBuddy's file editing tools are tracked.

### External Changes Are Not Tracked

Checkpointing only tracks files edited in the current session. Manual changes you make to files outside of CodeBuddy Code, and edits from other concurrent sessions, are typically not captured unless they happen to modify the same files as your current session.

### Not a Replacement for Version Control

Checkpointing is designed for quick session-level recovery. For permanent version history and collaboration:

- Continue using version control (like Git) to manage commits, branches, and long-term history
- Checkpointing complements version control rather than replacing it
- Think of checkpointing as "local undo" and Git as "permanent history"

---

## See Also

- **[Interactive Mode](interactive-mode.md)** - Keyboard shortcuts and session control
- **[Slash Commands](slash-commands.md)** - Use `/rewind` to access checkpoints
