Skip to content
| Marketplace
Sign in
Visual Studio Code>SCM Providers>Git Scan Fix - Manual Control & PerformanceNew to Visual Studio Code? Get it now.
Git Scan Fix - Manual Control & Performance

Git Scan Fix - Manual Control & Performance

vrocky

|
81 installs
| (0) | Free
🚀 Tired of VS Code's Git scanning slowing things down? This tool lets you manually open Git repositories when you need them, solving those annoying file-in-use errors and performance issues. No more automatic scanning - you're in control!
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

🚀 Git Scan Fix - Manual Control & Performance

Hey there! Ever noticed VS Code slowing down because it's constantly scanning for Git repositories? We've got a simple solution: manual control.

💡 What's This All About?

VS Code's Git features are great (especially with the new GitHub Copilot integration!), but there's a catch - it's always scanning your folders for Git repositories. This can:

  • 😫 Freeze your files with "file in use" errors
  • 🐌 Slow down your workspace
  • 🔥 Heat up your CPU
  • 🔋 Drain your laptop battery

Our solution? Let you manually open Git repositories when you need them.

🎯 How It Works

Instead of letting VS Code automatically scan everything:

  1. You decide when to open a Git repository
  2. Choose your preferred way to open it:
    • 📁 Pick from a file browser
    • ⚡ Quick-select from your workspace
    • ⌨️ Type the path directly
  3. No background scanning, no slowdowns!

🛠️ Quick Start

  1. Install this extension
  2. Use our one-click fix to disable automatic scanning
  3. Open repositories manually through:
    • Command Palette: Git Scan Fix: Open Repository
    • Keyboard Shortcut: Ctrl+Shift+G O
    • Quick Pick from workspace folders

About VS Code's Git Features

VS Code comes with an excellent built-in Git integration that has gotten even better with GitHub Copilot integration:

  • ✨ AI-powered commit message suggestions
  • 🤖 Smart Git commands and recommendations
  • 🔄 Automatic branch management
  • 📊 Rich diff viewing and merge conflict resolution

However, there's one significant drawback: continuous repository scanning.

🔍 The Problem with Git Scanning

While VS Code's Git features are powerful, the continuous repository scanning can cause:

  • ❌ File-in-use errors blocking your work
  • ❌ High CPU usage in large workspaces
  • ❌ Disk I/O slowdowns
  • ❌ Overall workspace performance degradation
  • ❌ Battery drain on laptops

🛠️ How to Control Git Scanning

Method 1: Use Our Quick Fix Commands

  • Use 🚀 Fix Git Scanning (Workspace) for current workspace
  • Use 🚀 Fix Git Scanning (Global) for all workspaces

Method 2: Manual Settings Configuration

  1. Via Settings UI:

    • Open Settings (Ctrl/Cmd + ,)
    • Search for "git.autoRepository"
    • Uncheck "Auto Repository Detection"
  2. Via settings.json:

{
    // Disable automatic Git repository detection
    "git.autoRepositoryDetection": false,

    // Optional: Additional performance tweaks
    "git.detectSubmodules": false,
    "git.detectSubmodulesLimit": 1,
    
    // Keep Git features enabled
    "git.enabled": true
}

Method 3: Workspace-Specific Control

Create or edit .vscode/settings.json in your workspace:

{
    "git.autoRepositoryDetection": false,
    "git.detectSubmodules": false
}

Best Practices

  1. Keep Git Features: Don't disable Git completely, just control the scanning
  2. Workspace Control: Start with workspace-level settings
  3. On-Demand Access: Use our commands to open repositories when needed
  4. Monitor Performance: Watch for improvements after disabling scanning

✨ The Solution

This extension provides:

  1. 🚀 One-click fix for Git scanning issues
  2. 📂 On-demand repository access
  3. 🔧 Simple workspace and global controls
  4. ⚡ Instant performance improvement
  5. 🤝 Full compatibility with VS Code Git features

Disabling VS Code's Git Auto Scan

To get the best performance, you can disable VS Code's automatic Git repository scanning:

  1. Open VS Code Settings (Ctrl+,)
  2. Search for "git.autoRepositoryDetection"
  3. Set it to false or add this to your settings.json:
{
    "git.autoRepositoryDetection": false
}

Additional Git-related settings you might want to adjust:

{
    "git.enabled": true,           // Keep Git features enabled
    "git.autoRepositoryDetection": false,  // Disable auto scanning
    "git.detectSubmodules": false, // Disable submodule scanning
    "git.detectSubmodulesLimit": 1 // Limit submodule depth if enabled
}

Features

  • No Background Scanning: Only scans when you explicitly request it
  • Multiple Ways to Open Repositories:
    • File Picker: Browse and select any repository
    • Workspace Quick Pick: Choose from Git repositories in your workspace
    • Direct Path Entry: Enter the repository path manually
  • Initialize New Repositories: Quick command to initialize Git in current folder

Why Use This Extension?

  1. Keep VS Code's Git Features: You still get all the great Git and GitHub Copilot features.
  2. Control When to Scan: Only scan for repositories when you explicitly want to.
  3. Better Performance: No background processes constantly checking your directories.
  4. Simple Workflow: Quick commands to open repositories when needed.
  5. Works Alongside: Use this extension in conjunction with VS Code's built-in Git features for enhanced control and performance.

🛠️ Commands

  • Git Scan Fix: 🚀 Fix Git Scanning (Workspace) - Fix scanning issues in current workspace
  • Git Scan Fix: 🚀 Fix Git Scanning (Global) - Fix scanning issues for all workspaces
  • Git Scan Fix: Open Repository (File Picker) - Browse and open repository
  • Git Scan Fix: Open Repository (From Workspace) - Quick pick from workspace
  • Git Scan Fix: Open Repository (Enter Path) - Enter repository path
  • Git Scan Fix: Initialize Repository - Initialize new Git repository

Usage Tips

  1. Use keyboard shortcut Ctrl+Shift+G O (Cmd+Shift+G O on Mac) to quickly open repositories
  2. Use the "Disable Git Auto-Scanning" command to automatically configure VS Code settings
  3. Use the workspace quick pick for faster access to your project repositories

Manual Git Refresh

When auto-scanning is disabled, you can manually refresh Git status:

  1. Use the built-in Git: Refresh command from the Command Palette
  2. Click the refresh icon in the Source Control panel
  3. Use the keyboard shortcut:
    • Windows/Linux: Ctrl+Shift+G R
    • Mac: Cmd+Shift+G R

This gives you full control over when VS Code updates Git status.

After Disabling Auto-Scanning

When you disable automatic Git scanning, you'll need to manually refresh Git status. Here are all your options:

1. Manual Refresh Options

  • Use Git: Refresh command (Ctrl/Cmd + Shift + G R)
  • Click the refresh icon in Source Control panel
  • Run git status in terminal

2. Alternative Workflows

  • Keep auto-scanning enabled for specific important folders
  • Use workspace-specific settings instead of global disable
  • Set up task automation for periodic Git status updates

3. Best Practices

  • Refresh before important Git operations
  • Use Source Control panel indicators
  • Check status manually when switching branches
  • Configure per-folder settings for critical projects

Performance Benefits

  • No continuous background scanning
  • Reduced disk I/O
  • Lower CPU usage
  • Fewer file system locks
  • Better overall workspace performance

Contributing

Feel free to file issues and submit PRs on our GitHub repository.

Git Commands Helper

A VS Code extension that provides helpful Git repository management commands.

Features

This extension adds several commands to help manage Git repositories in VS Code:

Git Repository Management

  • git-commands-helper.initGitRepo: Initialize a new Git repository
  • git-commands-helper.openRepository: Open a Git repository by browsing
  • git-commands-helper.openRepositoryFromSelection: Open a Git repository from workspace
  • git-commands-helper.openRepositoryFromPath: Open a Git repository from manual path input
  • git-commands-helper.disableGitScanning: Disable Git auto-scanning in workspace
  • git-commands-helper.disableGitScanningGlobally: Disable Git auto-scanning globally
  • git-commands-helper.refreshAllRepositories: Refresh all Git repositories
  • git-commands-helper.addRepositoriesFromDirectory: Add all Git repositories from a directory
  • git-commands-helper.addRepositoriesFromPath: Add Git repositories from manual path input
  • git-commands-helper.toggleKeybindings: Toggle extension keybindings

Default Keybindings

  • Initialize Git Repository: Ctrl+Alt+G I
  • Open Repository: Ctrl+Alt+G O
  • Open Repository from Selection: Ctrl+Alt+G S
  • Open Repository from Path: Ctrl+Alt+G P
  • Disable Git Scanning (Workspace): Ctrl+Alt+G D
  • Disable Git Scanning (Global): Ctrl+Alt+G G
  • Refresh All Repositories: Ctrl+Alt+G R
  • Add Repositories from Directory: Ctrl+Alt+G A
  • Add Repositories from Path: Ctrl+Alt+G M
  • Toggle Keybindings: Ctrl+Alt+G T

Keybindings can be enabled/disabled using the git-commands-helper.toggleKeybindings command.

Extension Settings

This extension contributes the following settings:

  • git-commands-helper.enableKeybindings: Enable/disable keyboard shortcuts (default: true)

Requirements

  • Visual Studio Code 1.80.0 or higher
  • Git extension for VS Code must be installed

Known Issues

No known issues at this time.

Release Notes

1.0.0

Initial release of Git Commands Helper

  • Added Git repository management commands
  • Added keybinding support
  • Added workspace and global Git scanning controls
  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft