3 ms·
Does it work on Windows?
by galaxyLogic 4y ago
Does it work on Windows?
- chriswarbo 4y agoIt works under WSL. I seem to remember some other experiments years ago (maybe cygwin/mingw based?)
- breakds 4y agoWe use NixOS and Nix extensively in the company. A few developers actually use NixOS on WSL as daily driver, and it was pretty smooth.
- pxc 4y agoThere's a community port of NixOS to WSL2, complete with systemd support, plus Docker Desktop support and some other goodies: https://github.com/nix-community/NixOS-WSL https://github.com/nix-community/NixOS-WSL Nix also works on other WSL distros, provided they're using WSL2. Nix supports cross-compiling Windows binaries as well. I know some people use it for that. There is no 'native' support— you can't use Nix as an alternative to Winget or Chocolatey on Windows. Right now a lot of important stuff in Nixpkgs depends on a POSIX shell and Unix coreutils implementation for the basic build environment, and that's shared between many operating systems. Trying to fit Windows into that doesn't really make sense, and there's not really any momentum behind the idea of using any particular other runtime environment (could be a scripting language instead of a shell + coreutils) for those basic builders. But it's conceivable that some day, one or more companies using Nix on WSL might see vaiue in taking that extra step and put together a Nix-based package collection for Windows and help get the Nix Windows port out the door. It also seems possible that a motivated Nix developer could take it somewhere on their own, since at least one has a workable PoC IIRC (but they didn't want to create/maintain a separate package collection). For now, it works very well with WSL2 and that's the way to go for Windows users.