Profpatsch / yarn2nix

Build and deploy node packages with nix from yarn.lock files.
MIT License
85 stars 21 forks source link

Drop hnix dependency #55

Open Profpatsch opened 3 years ago

Profpatsch commented 3 years ago

hnix is a parser & evaluator and generating/pretty printing nix expressions is just a side-effect of its functionality. Thus it has a giant amount of dependencies, and given that the Haskell ecosystem is prone to breakage (upper version bounds …), being able to build hnix from nixpkgs is a gamble.

We only generate a few nix expressions, which are relatively simple to string-concatenate, even with a little helper. Since nix is context-free and not whitespace-sensitive, simple interpolation of expressions is always correct.