Installing Diesel CLI in Windows 10 can be troublesome sometimes. When I did execute this command “cargo install diesel_cli –no-default-features –features postgres” and receive error message:
note: Non-UTF-8 output: LINK : fatal error LNK1181:error: linking with `link.exe` failed: exit code: 1181
I have tried to debug it with the various approach by:
- Is this because I use Mandarin in my Windows 10 default language? Which I did following this suggestion https://github.com/rust-lang/rustup/pull/1944
- Is this because I forgot to install Microsoft Visual Studio Package
So, I did reset my Windows 10 language and downloaded the gigantic Microsoft Visual Studio 2019 with “VC++ 2015.3 v14.00 (v140) toolset for desktop”. I did re-install rust with the hope it will solve the issue.
None of the above is works until I found someone wrote an article on how to install Diesel in Windows 10 and enable it’s CLI with the help of setup the local variable PATH.