tilapia
tilapia copied to clipboard
Cabal: Better name for "Nix-style local builds"
Cabal calls its version 2 build system "Nix-style local builds" and says
Nix-style local builds are a new build system implementation inspired by Nix.
I think this is likely to be very confusing for newcomers to the Haskell community, most of whom won't have heard of Nix, and I don't think it's even helpful for existing community members, most of whom won't have used Nix. I don't think "Nix-style" explains the build style clearly enough to be used up front. It may even mislead new users into thinking that Cabal actually uses Nix somehow.
What better terminology could we use? "persistent"? "immutable"? I don't have a particularly good suggestion.
Furthermore, Cabal v2-style builds are not supposed to be "reproducible" like Nix's, as far as I know.
More evidence that mentioning "Nix" confuses (potential) users
The documentation is notoriously lacking. As best I can tell, there are no “quick start” tutorials, and the relevant parts of the user manual are mentioned only under a heading that mentions “Nix”.
https://reasonablypolymorphic.com/blog/mea-culpa/
And regarding the above
one look at https://www.haskell.org/cabal/users-guide/ and you'd be forgiven for thinking it was some kind of Nix add-on.
https://old.reddit.com/r/haskell/comments/h99voy/polysemy_mea_culpa_reasonably_polymorphic/fuws35f/
When I was fighting with it last year there were these weird v2 commands, which I was supposed to use, but I didn't know why and for some reason are documented under the heading "nix-style local builds" where I promise you nobody will ever think to look for them. I know nix exists, but I don't really know what it does and I know that I don't use nix, so why would I possibly think to look under that heading?
https://old.reddit.com/r/haskell/comments/h99voy/polysemy_mea_culpa_reasonably_polymorphic/fux11lm/
Saw this issue linked in the Reddit comments on Sandy's post, and when re-reading some of the documentation I had a thought:
What better terminology could we use? "persistent"? "immutable"? I don't have a particularly good suggestion.
Why do we have to use descriptive terminology for what are now the standard cabal build
et al. commands (as of cabal-install-3.x
? As far as I'm aware, all other commonly used programming language build tools just refer to this as the normal way of building and installing dependencies.
Now that cabal v1-*
is a thing, could the documentation be rewritten to refer to these as "legacy" or "unsandboxed" builds, and the new ones would simply be "builds"?
You could put the explicit description of cabal-install
's "new" sandboxing behavior in the section on legacy builds to provide context for anyone digging that far down in the documentation.
Great ideas, thanks!
[And just in case it isn't clear: this is by no means an official issue tracker. It's just a place for me to make notes about things across the Haskell ecosystem that I want to improve. Feel free to stick around if you like!]
More evidence: https://news.ycombinator.com/item?id=24492071
Next step: submit a PR to cabal to remove mention of "Nix-style". As @jkachmar points out, this style is just the style that cabal uses. No need to name it!