A visual walkthrough of every major feature in vim-claude-code. Each demo runs in under 90 seconds against a real Go codebase.
Key:
<C-\>
- Press
<C-\>in Normal mode to open the Claude Code panel in a right split - Press
<C-\>again to hide it — your editor reclaims the full width - Press
<C-\>once more to restore — the session is never lost, conversation history intact - Works identically from Terminal mode inside the Claude panel
Command:
:Claude fix --apply
- Claude automatically detects the current function (or uses your visual selection)
- Identifies a SQL injection vulnerability (string concatenation in a query)
- Identifies a resource leak (rows never closed after a DB query)
- Patches both issues in place — no copy-paste required
- Shows a summary of changes in the Claude panel before writing to disk
Workflow:
Shift-Vto select, then:Claude test --edge-cases
- Enter Visual Line mode with
Shift-Vand select the function you want tested - Run
:Claude test --edge-cases— Claude receives exactly the selected lines as context - Generates 9 edge-case tests covering positive, zero, negative, overflow, and concurrency scenarios
- Test names follow the
Test<Func>_<Scenario>convention automatically - Works with any test framework; specify with
--framework <name>(e.g.,--framework testify)
Commands:
:Claude commit --conventionaland:Claude pr
:Claude commit --conventionalreads your staged diff and produces a Conventional Commit message with type, scope, and body:Claude prgenerates a full PR description with Summary, Changes, and Testing sections- Both commands are diff-aware — Claude only sees what is actually staged
- Use
--amendflag to rewrite the most recent commit message instead
Shortcut:
:Claude <Tab>
- All 22 sub-commands live under the single
:Claudenamespace - Type
:Claudethen press<Tab>to open the Vim completion popup - Continue typing to filter — e.g.,
:Claude re<Tab>showsrefactor,rename,resume,review - Each command description appears in the Claude panel as you cycle through
- No need to memorise anything — the full command set is always one
<Tab>away
Command:
:Claude explain· Flags:--brief,--detailed
- Without a visual selection, Claude detects and explains the current function
- With a visual selection active, explains exactly the selected lines
- Covers: what the function does, its inputs and outputs, error handling strategy, and any notable patterns
- Use
--brieffor a one-liner summary,--detailedfor a deep dive including data-flow notes - Highlighted lines in the editor show exactly what context was sent to Claude
Command:
:Claude refactor --extract
- Extracts inline validation or repeated logic into a named helper function
- The original handler becomes shorter and easier to read (single responsibility)
- Available refactor flags:
--extract·--simplify·--optimize·--rename - Claude respects existing naming conventions and package structure
- Changes are previewed in the Claude panel before being applied
Config:
let g:claude_code_position = 'right'(orbottom,top,left,float,tab)
right— Vertical split on the right (default, matches the screenshot)bottom— Horizontal split at the bottom (classic terminal feel)top— Horizontal split at the topfloat— Floating popup centred over the editor (requires+popupwin)tab— Claude lives in its own dedicated tab page- Switch layout at any time with
let g:claude_code_position = '<mode>'and re-open
Command:
:Claude doctor
- Runs 6 checks and reports
[OK]or[FAIL]for each:- Claude CLI found in
$PATH - Git installed
- Vim compiled with
+terminal - Vim version ≥ 8.1
+popupwinavailable (for float mode)- Claude authenticated (API key or OAuth)
- Claude CLI found in
- Run this first whenever something isn't working — it tells you exactly what to fix
Command:
:Claude chat
- Opens an input prompt at the bottom of the Claude panel
- Your current file is automatically included as context — no manual copy-paste
- Ask anything: architecture questions, code review requests, "how do I add rate limiting?", etc.
- Claude's response streams into the panel in real time
- Combine with
:Claude contextto preview exactly what context will be sent before asking
Config:
let g:claude_code_multi_instance = 1(default: on)
- Each git repository gets its own independent Claude Code session
- Switch between repos (e.g., a Go backend and a React frontend) without losing conversation history
- Sessions are keyed by git root — detected automatically via
git rev-parse --show-toplevel - Disable with
let g:claude_code_multi_instance = 0if you prefer a single global session
Config:
let g:claude_code_refresh_enable = 1(default: on)
- When Claude edits a file on disk, the corresponding Vim buffer reloads automatically
- No manual
:e!required — changes appear instantly in your editor - A notification message confirms which buffer was reloaded (disable with
let g:claude_code_refresh_notify = 0) - Polling interval configurable:
let g:claude_code_refresh_interval = 1000(ms)
Command:
:Claude review· Flags:--strict,--security
- Reviews your current diff (what you've changed since last commit)
--securityflag focuses Claude on: injection vulnerabilities, missing auth checks, error leakage, and unsafe input handling--strictflag catches style issues, missing tests, and unclear naming in addition to bugs- Issues are highlighted in the editor alongside the Claude panel explanation
- Run before every commit for a quick automated code review
Command:
:Claude analyze
- Analyses the current file across three dimensions:
- Complexity — cyclomatic complexity, lines of code, nesting depth
- Performance — N+1 query patterns, hot-path allocations, missing indexes
- Security — missing auth, exposed error details, unsafe type assertions
- Results organised by section in the Claude panel
- Suggestions are actionable — not just "this is complex", but "extract X into Y"
Command:
:Claude doc· Flags:--inline,--markdown
--markdowngenerates a standalone Markdown doc block (endpoint, request body, response, error codes)--inlineinserts GoDoc / JSDoc comments directly above the function in the source file- Selection-aware — document a single function or an entire file
- Follows the conventions of your language (GoDoc for Go, JSDoc for JS/TS, docstrings for Python)
- Output can be copied to your project wiki, README, or API reference docs
| Mode | Key | Action |
|---|---|---|
| Normal | <C-\> |
Toggle Claude Code terminal |
| Normal | <Leader>ce |
Explain |
| Normal | <Leader>cf |
Fix |
| Normal | <Leader>cr |
Refactor |
| Normal | <Leader>ct |
Test |
| Normal | <Leader>cd |
Doc |
| Normal | <Leader>cG |
Commit |
| Normal | <Leader>cR |
Review |
| Normal | <Leader>cp |
PR description |
| Normal | <Leader>ca |
Analyze |
| Normal | <Leader>cc |
Chat |
| Visual | <Leader>c + key |
Same commands, but on selection |
See README.md for the full configuration reference.














