4 ms·
Maybe Nix but with Lua?
by cturtle 5y ago
Maybe Nix but with Lua?
- zamalek 5y agoYou need a strictly pure functional language to do what Nix does. It's able to determine if something is already installed (in a specific state) because it calculates a hash of the output. Side effects throw a wrench in all of that.
- tadfisher 5y agoMoreover, you need a _lazy_ functional language, because otherwise you are building every package in nixpkgs when evaluating it.
- rixed 5y agoWouldn't that be possible to build packages definitions instead? Isn't that what Guix is doing?
- cturtle 5y agoThanks! I guess I need to learn more about Nix then :)
- naasking 5y agoThe language doesn't need to be lazy. Strict languages model laziness via explicit lazy values. For Nix, this would be some kind of explicit package type. Side effects are problematic though.
- SAI_Peregrinus 5y agoI feel like a logic programming language (e.g. Prolog) would be a better fit for what Nix is trying to do than a functional one like Nix. Of course those are even less familiar to most devs than functional languages, so it wouldn't solve the "weird new language" issue.