A Sublime Text plugin that runs Claude as a code reviewer on save, scoped to projects you care about.
Tools like watchexec popularized the idea of running arbitrary commands on file save — scoped to paths and extensions you care about, triggered automatically, no manual invocation. claude-watcher applies the same pattern to code review: save a file in a watched project and a Claude Code session opens in a Terminus panel asking for a quick review.
The alternative approaches don't hold up. Pasting files into a chat manually is friction you eventually stop doing. Letting an agent watch everything burns tokens reviewing every CSS tweak and produces noise you learn to ignore. The filter is the feature — reviews only fire on the projects and file types where you're actively building something.
Requirements: Sublime Text 4, Terminus, Claude Code CLI (claude available on your PATH)
Note: macOS only for v0.1. Linux may work but is untested.
-
Clone the repo into your Sublime packages directory:
git clone https://github.com/rockwellwindsor/claude-watcher \ "$HOME/Library/Application Support/Sublime Text/Packages/ClaudeWatcher" -
Copy the example settings file and configure your projects:
cp "claude_watcher.sublime-settings.example" "claude_watcher.sublime-settings"Then edit
claude_watcher.sublime-settingswith your watched projects and preferences. -
Restart Sublime Text.
Package Control support is a v1.x goal.
Settings live in claude_watcher.sublime-settings. Copy the .example file to get started.
| Key | Default | Description |
|---|---|---|
watched_projects |
[] |
List of project paths or name substrings to watch. Matched as substrings of the saved file's path — use a full path or just the project folder name. |
watched_extensions |
[".rb", ".tsx", ".js", ".ts", ".css", ".scss", ".erb", ".py", ".go"] |
File extensions that trigger a review. |
debounce_delay |
1.0 |
Seconds to wait after a save before triggering. Rapid saves collapse into one review. |
log_directory |
— | Directory where session logs are written. Created automatically if it doesn't exist. If unset, logging is skipped. |
Example watched_projects entries:
"watched_projects": [
"/Users/you/projects/my_app",
"side_project"
]Settings changes require a Sublime Text restart to take effect.
Toggle the watcher on/off:
Open the Command Palette (Cmd+Shift+P) and run Claude Watcher: Toggle. The status bar briefly confirms the new state. The watcher starts disabled on each Sublime launch.
Check current state:
Run Claude Watcher: Status from the Command Palette to see whether the watcher is enabled and what's currently configured.
Expected behavior on save:
When you save a watched file, after the debounce delay a Terminus panel opens titled Claude - <project> and runs a Claude Code review of the saved file. If a panel for that project already exists, the session continues — Claude has context from earlier saves. The previous session's content is logged to disk before the panel is replaced.
- macOS only for v0.1. Linux likely works (untested); Windows is a different story.
- Terminus required. The plugin will fail silently on save if Terminus isn't installed.
- Global enabled state. The toggle is a module-level boolean that resets to
Falseon each Sublime launch. There's no persistence. - Settings require restart. Changes to
claude_watcher.sublime-settingsdon't take effect until Sublime restarts.
- v1.x: Submit to Package Control
- v1.x: Test and document Linux compatibility
- v1.x: Surface a startup error if Terminus isn't installed
- v1.x: Settings hot-reload without restart
MIT