News for hackers. Stuff that matters.
Re:Rust for Windows by chx on Thursday January 21, 2021 @03:26PM (#25863761)
> WSL2 is so freaking good.

I am on WSL1 two things hold me back from upgrading

1. How's networking? I go on and off VPNs quite a bit.

2. How's cross system access to files especially performance wise? I edit with phpstorm for windows, I share the files with Slack also windows, I access the same files with WSL git, LAMP stack and more.

Re:Rust for Windows by kyriakos on Thursday January 21, 2021 @03:38PM (#25863918)
1. Just works. Only issue I found is that Wsl2 will not update its dns resolver IPs when connecting to the vpn. There's a workaround script. So it's either exit the terminal and re enter it or run the script to update them.

2. This is my current pain. Windows file system is slow already and accessing it from wsl adds an overhead. Ideally I keep projects in Wsl2 storage and IDEs in Windows. I searched a lot for a solution but haven't found one. On the other hand, Wsl2 Linux storage speed runs circles around wsl1.

Re:Rust for Windows by mynameisash on Friday January 22, 2021 @12:11AM (#25868542)
I never had an issue with WSL1 until some bizarre bug that cropped up seemingly out of nowhere in which I would blue-screen during some Rust compilation. I didn't have the issue after maybe four or six months of using Rust in WSL1 until suddenly I did. Upgrading to WSL2 fixed the problem.

Publishing Rust crates does require a workaround[0] in WSL2 if it's from a Windows directory. That's annoying but pretty infrequent (for me) and not a difficult workaround.

Except for those two issues, I've not had any problems in either WSL version - certainly nothing that would give me pause to using either one.

[0] https://github.com/rust-lang/cargo/issues/8439#issuecomment-...

Re:Rust for Windows by peschkaj on Thursday January 21, 2021 @03:58PM (#25864151)
I use X410 and run tools from inside of WSL2 by exporting the display. Works well for Emacs, JetBrains Rider, and every other GUI application I've tried so far.
Re:Rust for Windows by naikrovek on Thursday January 21, 2021 @04:20PM (#25864403)
Concur. X410 is great and survives where xming and vcxsrv both crash for me. It's not free but the "not crashing" feature makes it well worth the $10 I paid for it.
Re:Rust for Windows by girvo on Thursday January 21, 2021 @05:42PM (#25865568)
That sounds excellent: I’ll have to give it a shot. VSCode under WSL2 with its Docker support is neat, but can be slow due to the storage system overhead. This might solve that for my team!
Re:Rust for Windows by baq on Friday January 22, 2021 @05:10AM (#25870217)
re 2) try NFS exports on either host windows or WSL2. i've used an nfs mount inside WSL2 and it works very well. don't put it in /etc/fstab, though - for me it caused a WSL2 hard lock on start.
Re:Rust for Windows by ben-schaaf on Thursday January 21, 2021 @08:43PM (#25867188)
> As a rule of thumb, WSL 2 accessing host (NTFS) files is about 5 times slower than WSL 1 accessing those same files.

https://vxlabs.com/2019/12/06/wsl2-io-measurements/