Closed slikts closed 5 years ago
Have you tried setting the Windows environment variable WSLGIT_USE_INTERACTIVE_SHELL
to false
, as mentioned in the Readme?
This should significantly speed up wslgit, but it assumes that you do not rely on anything in .bashrc
to be run before git (like e.g. ssh-agent
or similar tools).
Other than that, I don't think you can configure different git versions for different commands in VS Code. In the latest release, wslgit only does additional work on the output of a few selected commands (diff
not included). In most cases, input and output is directly passed to/from git. So the overhead is likely from bash, which can be circumvented using above flag.
Thanks, setting that variable worked, although I'm not sure why it wouldn't be the default behavior.
Great, thanks for reporting back.
The current behavior is mainly for historic and compatibility reasons. The first versions used interactive bash sessions because wsl.exe
was not around back then and it is common to start tools like ssh-agent
or gpg-agent
for key management in .bashrc
, which, by default, is only fully executed for interactive shells.
But I may make the improved behavior the default in the future.
It'd be fine if just the commit was slow, but using wsligit makes the diffs just too slow to be usable. Is there some way to limit wslgit to just the commits?