Category Theory
Zulip Server
Archive

You're reading the public-facing archive of the Category Theory Zulip server.
To join the server you need an invite. Anybody can get an invite by contacting Matteo Capucci at name dot surname at gmail dot com.
For all things related to this archive refer to the same person.


Stream: practice: software

Topic: Nix/NixOS


view this post on Zulip Owen Lynch (Mar 13 2021 at 00:53):

I know there's a big overlap between the Haskell and category theory communities, and a big overlap between the Haskell and Nix/NixOS communities, and I'm kind of curious if there is an overlap between the category theory and Nix/NixOS communities!

For those who have not heard of Nix, it is a purely functional package manager that enforces reproducability of software builds: https://nixos.org. Basically, it completely solves the "well it works on my machine" problem: if you have told nix how to build your software, it can build your software anywhere. NixOS is an operating system built around the nix package manager.

There may or may not be any interesting category theory problems in Nix, but from an aesthetic standpoint, it might be attractive to a lot of category theory folks; and I'd love to say hi to anyone else who uses it!

view this post on Zulip Nick Hu (Mar 13 2021 at 11:00):

Hi Owen, I'm a regular contributor to nixpkgs. Good to see some love for nixos here!

view this post on Zulip Javier Prieto (Mar 14 2021 at 07:24):

I tried to install NixOS maybe a week ago, it failed for a reason I can't remember and I gave up. But I'm still super interested so I'll give it another spin soon. My main concern is the libraries ecosystem. I won't be able to switch completely until I'm sure there's a good Nix/NixOS replacement for everything I do with apt/Ubuntu.

view this post on Zulip Fintan Halpenny (Mar 14 2021 at 07:39):

I run my laptop on NixOS :grinning_face_with_smiling_eyes: I followed this guide if it's any help to you @Javier Prieto
https://github.com/qfpl/blog/blob/master/content/posts/installing-nixos.md

view this post on Zulip Fintan Halpenny (Mar 14 2021 at 07:40):

I still mostly cargo cult Nix but it's something I'd like to improve on down the line

view this post on Zulip Javier Prieto (Mar 14 2021 at 07:41):

Awesome, thanks! fwiw my issue probably had more to do with the fact that I was trying to install it on virtual box and my laptop RAM couldn't handle it

view this post on Zulip Nick Hu (Mar 15 2021 at 09:23):

There is a virtual box appliance available to download instead of an ISO on nixos.org, I would recommend that because there are some gotchas wrt virtualbox

view this post on Zulip Nick Hu (Mar 15 2021 at 09:24):

What libraries in particular are you concerned about? The coverage of packaged software is very comprehensive these days, which was less true say 5 years ago or so (where you might encounter old blog posts about nix)

view this post on Zulip Javier Prieto (Mar 15 2021 at 11:01):

What libraries in particular are you concerned about?

Well, that's the problem with unknown unknowns. I won't miss them until it's too late.

view this post on Zulip Nick Hu (Mar 15 2021 at 11:05):

Maybe if you gave me a particular ecosystem you're interested in I can give more specific guidance? For instance, every Haskell library on Hackage is automatically packaged effectively

view this post on Zulip Javier Prieto (Mar 15 2021 at 11:23):

Let's see... Other than haskell:

view this post on Zulip James Wood (Mar 15 2021 at 12:38):

I'm fairly sure all this stuff is packaged (I had to check calibre and vcv-rack because I've never heard of them, but they're there). I don't know how easily the middle three can be used; you sometimes find that Nix doesn't take kindly to other package managers, but sometimes it does.

view this post on Zulip Owen Lynch (Mar 15 2021 at 22:45):

There actually is anaconda support for Nix! The way it works is through this thing called a "FHS", which basically chroots into a more-standard-looking directory setup so that non-nix programs can find their dependencies. I use conda a lot for python stuff, because there are some (not a lot) of python libraries that are not included in NixOS

view this post on Zulip Owen Lynch (Mar 15 2021 at 22:47):

I just majorly refactored my julia setup to use a FHS environment along with conda support, so basically all of my "scientific software" is installed in a non-nixy way, but it plays nicely with the rest of my system which is very nix-y!

view this post on Zulip Owen Lynch (Mar 15 2021 at 22:48):

@Javier Prieto , if you use VSCode, then you always have the option of remoting into a docker container if you are struggling with installing something on nix, which has saved me a couple times!

view this post on Zulip Javier Prieto (Mar 16 2021 at 08:45):

That's always an option, yeah