Notification texts go here Contact Us Buy Now!

Many rg commands started by vscode that consume 99% of CPUs

Problem: Many rg commands started by vscode consume 99% of CPUs.

Cause:

  • There are four symlink folders with over 700k files in them, which are usually ignored in /project-root/.gitginore.
  • The --no-ignore-parent --follow flags are being used, which causes rg to search in these folders.

Solution 1:

  • Add the folders to /project-root/project-1/subproject-a/.gitignore again.
  • The rg commands should no longer consume so much CPU resource.

Solution 2:

  • Disable the Auto Import extension in vscode.
  • This may resolve the issue for some users.

Code:


# In /project-root/project-1/subproject-a/.gitignore
**/symlink-folder-1/*
**/symlink-folder-2/*
**/symlink-folder-3/*
**/symlink-folder-4/*

Post a Comment

Cookie Consent
We serve cookies on this site to analyze traffic, remember your preferences, and optimize your experience.
Oops!
It seems there is something wrong with your internet connection. Please connect to the internet and start browsing again.
AdBlock Detected!
We have detected that you are using adblocking plugin in your browser.
The revenue we earn by the advertisements is used to manage this website, we request you to whitelist our website in your adblocking plugin.
Site is Blocked
Sorry! This site is not available in your country.