A VS Code extension that helps you enter your optimal coding flow state by intelligently managing your workspace layout for maximum focus and productivity.
Visual demonstration of how Vibe Mode transforms your VS Code workspace for optimal focus and flow state.
This extension provides commands to optimize your VS Code layout for deep focus work:
- Vibe On (
vibe-mode.vibeOn) - Enter your flow state with optimal layout configuration - Vibe Off (
vibe-mode.vibeOff) - Exit flow state and restore default VS Code layout
- Automatically cleans conflicting UI elements
- Opens Copilot chat in editor for AI assistance
- Moves terminal to left for better workflow
- Hides sidebar and activity bar for maximum focus
- Smart conflict detection and resolution
- Restores activity bar to default position (visible, left)
- Moves panel/terminal back to bottom position
- Shows sidebar and normal UI elements
- Opens chat in normal sidebar/panel mode
- Creates new empty editor in center
- Ensures status bar is visible
This extension includes enhanced logic to resolve layout conflicts that can occur when multiple editors, Welcome tabs, or other UI elements compete for space with your focused workflow.
- Detects Welcome tabs that conflict with optimal layout
- Identifies multiple open editors that create clutter
- Recognizes when sidebar and panels interfere with focus
- Closes all conflicting editors before entering Vibe Mode
- Hides sidebar, activity bar, and unnecessary panels
- Provides a clean slate for optimal focus and flow
- Includes comprehensive logging for troubleshooting
Run the "Vibe Mode: Vibe On - Enter Flow State" command from the Command Palette to enter your optimal coding flow state with automatic conflict resolution.
Run the "Vibe Mode: Vibe Off - Exit Flow State" command to restore the default VS Code layout when you're done with focused work.
- "Vibe Mode: Vibe On - Enter Flow State" - Complete flow state optimization
- "Vibe Mode: Vibe Off - Exit Flow State" - Restore default VS Code layout
- Clean Slate Approach: Closes all conflicting editors and tabs
- UI Minimization: Hides non-essential UI elements (sidebar, activity bar, panels)
- Terminal Optimization: Positions terminal on the left for better workflow
- Focus Integration: Opens tools (like Copilot) in the optimal editor position
The extension detects and resolves common layout conflicts:
- Multiple open editors competing for space
- Welcome tab interfering with focused workflow
- Sidebar and activity bar reducing available space
- Bottom panels creating visual clutter
workbench.action.chat.openInEditor- Opens Copilot in editor modeworkbench.action.positionPanelLeft- Moves terminal to leftworkbench.action.closeSidebar- Hides the sidebarworkbench.action.activityBarLocation.hide- Hides the activity barworkbench.action.closeAllEditors- Cleans up conflicting editors
- VS Code version 1.74.0 or higher
- GitHub Copilot extension (recommended for AI-assisted coding workflows)
- Clone this repository
- Open the folder in VS Code
- Press
F5to run the extension in a new Extension Development Host window - Use the Command Palette (
Ctrl+Shift+PorCmd+Shift+P) to access the commands
This extension contributes the following commands:
vibe-mode.vibeOn: Vibe On - Enter Flow State (with conflict resolution)vibe-mode.vibeOff: Vibe Off - Exit Flow State (restore default layout)
- Requires GitHub Copilot extension to be installed for AI-assisted workflows
- Some VS Code commands may not be available in all environments
- Layout changes are immediate and can be reversed using Vibe Off command
- Initial release with basic layout management
- Commands for focused workflow, terminal, and sidebar management
- Comprehensive test suite
- π― Rebranded to "Vibe Mode" - Enter your optimal coding flow state
- Enhanced conflict resolution - Intelligent layout optimization
- Vibe On/Off workflow - Seamless entry and exit from flow state
- Improved Welcome tab handling and multi-editor conflict resolution
- Clean Layout command for aggressive workspace optimization
- Enhanced logging and debugging capabilities
- 108+ comprehensive tests including layout conflict scenarios
The extension includes comprehensive test coverage with 108+ tests covering:
- Unit Tests: Individual function testing
- Integration Tests: Command registration and execution
- Layout Tests: Real layout state verification
- Conflict Resolution Tests: Welcome tab and multi-editor scenarios
- Visual Layout Tests: UI component positioning
- Error Handling Tests: Graceful failure scenarios
- Vibe Mode Tests: Flow state entry and exit
Run tests with:
npm testEnjoy your optimal coding Vibe Mode! π―π
Ensure that you've read through the extensions guidelines and follow the best practices for creating your extension.
You can author your README using Visual Studio Code. Here are some useful editor keyboard shortcuts:
- Split the editor (
Cmd+\on macOS orCtrl+\on Windows and Linux). - Toggle preview (
Shift+Cmd+Von macOS orShift+Ctrl+Von Windows and Linux). - Press
Ctrl+Space(Windows, Linux, macOS) to see a list of Markdown snippets.
Enjoy!
This extension includes comprehensive automated tests to ensure reliability and functionality.
# Run all tests (54 tests total)
npm test
# Run tests with watch mode during development
npm run watch
# Compile and lint before testing
npm run pretestThe extension includes five types of tests:
- Unit Tests (
src/test/extension.test.ts) - Test individual functions and command registration with mocking - Integration Tests (
src/test/integration.test.ts) - Test extension activation and command availability in VS Code environment - Basic Functionality Tests (
src/test/basic.test.ts) - Test core VS Code API integration and package validation - Layout Position Verification Tests (
src/test/layout-positioning.test.ts) - Test component positioning and layout state changes - Real Layout State Verification Tests (
src/test/real-layout-verification.test.ts) - Test actual workspace layout inspection and validation - Visual Layout State Tests (
src/test/visual-layout.test.ts) - Test actual component positioning and layout state validation
- β Extension activation and deactivation
- β Command registration verification
- β Error handling and fallback mechanisms
- β Package.json validation
- β VS Code API integration
- β Mock testing for command execution
- β Panel position verification (left, right, bottom states)
- β Sidebar visibility state tracking (show/hide states)
- β Copilot editor positioning (fallback command testing)
- β Complete layout setup verification (all components positioned correctly)
- β Layout state persistence (configuration tracking)
- β Real workspace layout inspection (actual VS Code environment testing)
- β Component state detection (terminal, sidebar, Copilot availability)
- β Error recovery and resilience (graceful failure handling)
- β Visual component positioning (actual command execution and state verification)
The comprehensive layout positioning tests verify that components and layout elements are correctly positioned:
- Activity Bar Hiding: Tests that the activity bar (primary sidebar) is properly hidden using
workbench.action.activityBarLocation.hide - Panel Position Changes: Verifies terminal panels correctly move from bottom/right to left position using
workbench.action.positionPanelLeft - Sidebar State Management: Tracks sidebar visibility state and ensures proper hide/show functionality
- Component State Tracking: Monitors all layout components (panel position, sidebar visibility, Copilot status)
- Command Sequence Verification: Ensures the correct VS Code commands are called in proper order
- Fallback Behavior: Tests that alternative commands work when primary commands fail
- State Persistence: Verifies layout changes persist and are reflected in VS Code configuration
- Configuration Validation: Tests that layout configuration values are correctly set and accessible
- Real Environment Testing: All tests run in actual VS Code instance with real command execution
