Suggestion: deprecate the global default package environment file
jaror:
So I’d rather see further limitations of that instead of changing
ghc’s behavior. For example we could say--libis only allowed if you also provide--package-env. You could still say--package-env=default
Well, that would also be a breaking change.
Related issues:
- [RFC] Revive cabal sandboxes (UX) · Issue #10098 · haskell/cabal · GitHub
- Separate
cabal install --libinto own command (cabal env) · Issue #6481 · haskell/cabal · GitHub - [UX] Current mechanism to install several libraries and expose them to the user? · Issue #9581 · haskell/cabal · GitHub
I personally think for something like cabal install --lib, which is by nature an imperative command, the default should indeed be to install globally. That’s what 98% of the package managers do and what users are generally used to.
The problem is that cabal’s UX is now a hot mess, with some semi-declarative interface that doesn’t actually go all the way. And now people mix both of those paradigms and cabal isn’t very good at separating those. This is what sandboxes were good at: imperative, but local.
Discussion in the ATmosphere