Hacker Read top | best | new | newcomments | leaders | about | bookmarklet login

I spent a lot of time setting up Nix and NixOS to replicate my current dotfile environment on Debian I've spent years developing and which I can deploy on a new machine with a one liner. I really like Nix and found their DSL fairly easy to pick up, I didn't keep it for my desktop, workstation, or servers though for a few reasons.

1) Package availability: this is by far the largest reason. I frequently need to use software or specific versions that are just not available and while I did create some packages myself it is just too much work when I need to get something done.

2) Language Documentation.

3) I still need to use cargo and pip anyway.

4) Even when packages were available they often lacked the configuration options I needed and I would have to fork and edit them anyway.

I do think Nix is a lot better than current systems though.



view as:

I use pip all the time in NixOS. I just run it in a nix-shell, and install from a requirements.txt when the Python package is not in the nix packages.

I created a template which to the extent that I used it completly replaces the need for virtualenv and integrates well with declarative setuptools: https://github.com/takeda/example_python_project

With direnv + lorri when you enter the directory, it is as if you enter virtualenv, your code behaves as if it is installed with pip -e, if you call nix build it takes care of all dependencies and the command created in bin/ behave like binaries, have all dependencies needed.

I plan to update nixpkgs code that processes setup.cfg and make this less trivial example when I find some time.


Legal | privacy