-
Notifications
You must be signed in to change notification settings - Fork 4
Vimteractive v3: Dual Backend Architecture with Enhanced AI Support #40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
williamjameshandley
wants to merge
25
commits into
master
Choose a base branch
from
vimteractive3
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…active into vimteractive3
- Add CLAUDE.md for AI assistant guidance - Update README.rst to reflect tmux/vim-slime architecture - Document new dependencies (tmux, vim-slime, xdotool) - Add aichat to supported REPLs list - Fix configuration variable names (default_shells → default_repls) - Document response retrieval for all supported REPLs - Update help documentation with new features and requirements 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Based on GPT-5 review, fixed multiple issues: Code fixes: - Fix :Iterm command to properly autodetect (was passing '-auto-') - Fix g:vimteractive_terminal typo (was checking 'termina') - Remove debug echo from aichat response retrieval - Remove duplicate autoload/new.vim file Documentation updates: - Update docs to reflect external terminal/tmux architecture - Fix bracketed paste configuration (list not dict) - Document Visual mode Ctrl-Y behavior - Add zsh prompt configuration variables - Add perl and col dependencies for zsh - Remove references to unimplemented g:vimteractive_slow_prompt - Clarify :Iconn uses tmux pane names, not buffers 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Major architectural change to support both backends: - vim's native terminal (no external dependencies) - tmux with external terminals (original behavior) Changes: - Add dispatcher pattern in main vimteractive.vim - Create backend/ directory with tmux.vim and vimterminal.vim - Move common functions to common.vim - Add g:vimteractive_backend configuration (default: 'tmux') - Update documentation for both backends Benefits: - No external dependencies with vimterminal backend - Full backward compatibility with tmux backend - Both backends can work simultaneously - Clean, extensible architecture Based on architecture advice from Gemini AI analysis. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Fixes and improvements based on architectural review:
Bug fixes:
- Fix division by zero in tmux next_term/prev_term when no panes exist
- Remove g:slime_target setting from dispatcher (now only set in backends)
Code quality improvements:
- Extract common REPL setup logic to vimteractive#common#prepare_repl_info()
- Reduce code duplication between tmux and vimterminal backends
- Make vimterminal split command configurable via g:vimteractive_vimterminal_config
Configuration example for vimterminal users:
let g:vimteractive_vimterminal_config = {'split_command': '30vsplit'}
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
The dispatcher was using exists() to check for function existence, but this doesn't trigger vim's autoload mechanism. Changed to use try-catch with call() which properly triggers autoload when calling functions in backend/*.vim files. Also fixed show_term in tmux backend to check for slime_config existence before accessing it. Co-Authored-By: Claude <noreply@anthropic.com>
Changed all REPL commands from strings to lists to handle complex quoting correctly. This ensures arguments with spaces or quotes are properly escaped when passed to subprocesses. - Updated common.vim to handle list commands and substitute placeholders - Modified tmux backend to shell-escape and join list arguments - Converted all command definitions in plugin/vimteractive.vim to lists This fixes the ipython logfile quoting issue and provides a more robust foundation for command handling across backends. Co-Authored-By: Claude <noreply@anthropic.com>
Removed explicit split creation and curwin option. Now term_start() handles window creation directly, matching the behavior of the master branch and providing standard vim terminal split behavior. Also fixed duplicate window issue by removing redundant split command. Co-Authored-By: Claude <noreply@anthropic.com>
Silenced the file rename command to prevent vim from showing the buffer modification message, which was triggering the 'Press ENTER' prompt. Kept the 'Connected to' message for consistency with tmux backend. Co-Authored-By: Claude <noreply@anthropic.com>
Updated README.rst, CLAUDE.md, and doc/vimteractive.txt to document the new dual backend support (tmux and vimterminal). Added: - Migration instructions for v2 users who want vim's native terminal - Clear explanation of backend differences and configuration - Updated dependencies for each backend - Comprehensive options documentation - Architecture details for the dispatcher pattern This ensures users understand how to choose between external tmux terminals and vim's built-in terminal based on their needs. Co-Authored-By: Claude <noreply@anthropic.com>
The dispatcher was using exists() to check for function existence, but this doesn't trigger vim's autoload mechanism. Changed to use try-catch with call() which properly triggers autoload when calling functions in backend/*.vim files. Also fixed show_term in tmux backend to check for slime_config existence before accessing it. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
- Updated default REPL documentation to match code (empty string = filetype detection) - Fixed remaining string command example to use list format - Documentation now accurately reflects actual behavior 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This is a major rewrite of vimteractive introducing dual backend support and enhanced AI assistant integration.
Key Features
Architecture Changes
tmux: External terminals via tmux (default for backward compatibility)vimterminal: Vim's native terminal (no external dependencies)New Dependencies
Core (both backends):
Tmux backend only:
Vimterminal backend:
Configuration
Migration from v2
For users who want the v2 experience (vim's native terminal):
Security & Robustness Improvements
Documentation
Test plan
🤖 Generated with Claude Code