Live data from Hacker News

Ask HN: Windows Dev Setup?

news.ycombinator.com

21–30 of 34 posts

Re: Ask HN: Windows Dev Setup?

#21

You can avoid the awfulness of chocolatey by sticking with WSL2. Install that, docker desktop, windows terminal and vscode, voila you are back in linux land and can completely avoid powershell and windows broken file names.

If you avoid PowerShell, go back to where you came from :) Avoid bad advices.

I realise powershell has fans, but hear me out.

Windows itself has reached a dead end. It is such a mishmash of incompatible tech that Microsoft themselves have stopped trying to fix their admin GUI interface. Between registry, Com and Dcom and even a few leftover text files, there is no way to configure a windows system consistently.

Powershell is an over complicated band-aid to cover it up, ignoring that the wound underneath has become septic.

I get that they had to do something to drag it together, but even good powershell scripts end up as 4 different coding styles crammed together, depending on what component CLI output or interface you are trying to use.

WSL2 is a great thing if you need to do anything with python, node and even .NET. All the online tutorials work and since everything is a CLI these days, why not use a decent shell that doesn't have windows legacy character escape bogosity, broken file names and has sane argument handling?

Re: Ask HN: Windows Dev Setup?

#22

Earlier quoted context omitted.

If you avoid PowerShell, go back to where you came from :) Avoid bad advices.

I realise powershell has fans, but hear me out. Windows itself has reached a dead end. It is such a mishmash of incompatible tech that Microsoft themselves have stopped trying to fix their admin GUI interface. Between registry, Com and Dcom and even a few leftover text files, there is no way to configure a windows system consistently. Powershell is an over complicated band-aid to cover it up, ignoring that the wound…

> Powershell is an over complicated band-aid to cover it up

Sounds like personal preference or non RTFM. Bash is IMO way more complicated, I wouldn't touch it even if my life depended on it. Even authors hate it.

> Windows itself has reached a dead end. It is such a mishmash of incompatible tech that Microsoft themselves have stopped trying to fix their admin GUI interface. Between registry, Com and Dcom and even a few leftover text files, there is no way to configure a windows system consistently.

Yet Linux is not a single system but array of distributions and when you take all into account, you have worst situation then with Windows. Not really comparable IMO.

> WSL2 is a great thing if you need to do anything with python, node and even .NET.

Nah, those work perfectly fine without WSL2. There are things that require it, and that is reason its great (for example Home Assistant).

> why not use a decent shell that doesn't have windows legacy character escape bogosity, broken file names and has sane argument handling?

I use decent terminal - ConEmu. Its like tmux, and better since it allows embedding GUIs in splits rather then just shell. Hard to find better thing on Linux.

I use most powerful shell in existence. I use it cross platform.

> and has sane argument handling?

Are you serious? Bash argument handling must be the worst out there. I might be able to understand other complaints but this one is really lame.

> broken file names

What?

Re: Ask HN: Windows Dev Setup?

#23
I run Arch Linux in Hyper-V on 11 Pro.

Services (NGINX, MariaDB, PHP/PHP-FPM, etc.) are within Arch.

Project files are in Windows, mounted as an NFS share within Arch.

Editing and committing files mostly from Windows, Atom and git configured for LF.

Executing tasks, Bash scripts and such, from Arch via SSH.

I tend to duplicate tasks in Batch or Powershell for cross-compatibility.

And use the same structure for Electron builds on the Windows side with WIX.

Only complaint is VM performance.

I'll probably swap to a bare-metal Linux machine, using the same approach, soon.

Re: Ask HN: Windows Dev Setup?

#24

Earlier quoted context omitted.

If you avoid PowerShell, go back to where you came from :) Avoid bad advices.

I realise powershell has fans, but hear me out. Windows itself has reached a dead end. It is such a mishmash of incompatible tech that Microsoft themselves have stopped trying to fix their admin GUI interface. Between registry, Com and Dcom and even a few leftover text files, there is no way to configure a windows system consistently. Powershell is an over complicated band-aid to cover it up, ignoring that the wound…

Powershell always feels like writing enterprise editions (like https://github.com/EnterpriseQualityCoding/FizzBuzzEnterpris...) of simple tasks.

Re: Ask HN: Windows Dev Setup?

#25
WSL2 all the way. I didn't like Chocolatey.

Just make sure that your actual code/project files are also inside of your WSL (https://dev.to/ajeet/so-you-have-installed-windows-subsystem...)

There's a thing called WSL Bridge that VS Code hooks into, or uses somehow in order to run VS Code in Windows, but it is accessing and running code that's inside the WSL.

I used various terminal programs but the most recent one I used was Windows Terminal: https://www.microsoft.com/en-us/p/windows-terminal/9n0dx20hk...

This alleviated many issues I had and I ended up getting my whole team onboard with the same setup.

We were running Angular apps, and also vanilla JS stuff with Bootstrap, Gulp, Webpack, Live Server.

Re: Ask HN: Windows Dev Setup?

#26
If you can build/run code in a linux environment:

wsl2 gives you linux vm running in hyper-v alongside windows.. the vm pretty much has direct hardware access and is fast. From here, you can install linux based git, rsync, etc ... and the vm has full access to the windows filesystem.

vscode has a nice wsl extension which runs in client/server mode with server living in the linux vm and client on windows.

wsltty is closest feeling simple terminal, with translucency, etc.

... with this setup, i got rid of cygwin, vagrant, virtualbox, etc.

Re: Ask HN: Windows Dev Setup?

#27
A simple tip: with WSL/WSL2, you can run XServer process in Windows and your IDE launched inside WSL will show up as just another window in your Windows task bar (you have to point it at the Xserver). It completely eliminates the annoying double desktop/double taskbar setup that's normally a drawback of using a VM.

Re: Ask HN: Windows Dev Setup?

#28
All I'll say is, good luck. I was/am in the same boat and unfortunately for me it'll be the difference between staying in the role and potentially moving on in the future. WSL2 is decent, but there are some fundamental incompatibilities that in some cases make it unusable in a professional context. Everything feels a bit second rate to MacOS/Linux development - tooling, hardware, OS design, peripherals. Ultimately, I'd do almost anything to go back to a Mac and feel like I'm working at 100% efficiency again.

Re: Ask HN: Windows Dev Setup?

#29
I think the best solution is to ask your coworkers how they provision their dev environments, because windows dev is such shit that you don't want to struggle to build and run other peoples' code in the office.
Post reply on HN