aztfmod / rover

The rover is a docker container in charge of the deployment of the Terraform platform engineering for Azure
MIT License
171 stars 142 forks source link

ZSH is super slow on Windows #244

Closed LaurentLesle closed 2 years ago

LaurentLesle commented 2 years ago

We identified ZSH can be very slow when running on Windows with zsl2. I am opening this issue to track the discussions on that topic.

After initial investigation we found:

  1. Docker desktop may not be configured to properly use the resources available on your machine.
  2. zsh is slow when pressing enter command

Proposed solutions:

Problem 1

Create a .wslconfig and the maximum amount of memory and CPU You can set 3 to 4 GB of RAM and 0 to use the maximum number of CPU. Terraform plan will run faster with more virtual CPUs https://docs.microsoft.com/en-us/windows/wsl/wsl-config#configuration-setting-for-wslconfig

Problem 2

https://stackoverflow.com/questions/12765344/oh-my-zsh-slow-but-only-for-certain-git-repo Disable the hide-dirty function

git config --add oh-my-zsh.hide-dirty 1