vscode-hg icon indicating copy to clipboard operation
vscode-hg copied to clipboard

Only run hg for the working directory

Open Kurunato opened this issue 5 years ago • 1 comments

I noticed that on startup of vscode the Output for Hg had a bunch of hg root commands for directories that are under ../vendor. I also noticed that the same thing happens for other directories when opening files that are not in the working directory or workspace. I have several directories in my workspace, and only one of them uses hg. Is it possible to configure the extension to only run commands for a specified directory?

Examples:

hg root
abort: no repository found in '/var/www/html/extlib/vendor/swaggest' (.hg not found)!
hg root
abort: no repository found in '/var/www/html/extlib/vendor/symfony' (.hg not found)!
hg root
abort: no repository found in '/home/test.user/.vscode-server/data/Machine' (.hg not found)!

vscode Version: 1.48.0 extension Version: 1.7.1

Kurunato avatar Aug 22 '20 06:08 Kurunato

Hi @Kurunato!

This is the default behavior of the extension, and it is consistent with Git's extension as well. hg root shouldn't be expensive to run. Is it causing an issue?

hdpoliveira avatar Aug 30 '20 16:08 hdpoliveira