Use easy-purescript-nix as an overlay

I can’t for the life of me figure out how to do this.

This is what I’ve tried, with multiple variations of it, and keep on getting a segfault. Any suggestions?

I’m putting this in a file ~/.config/nixpkgs/overlays/easy-ps.nix

self: super:

let
  easy-ps = import (builtins.fetchGit { url = "https://github.com/justinwoo/easy-purescript-nix.git"; }) {};
in 
  builtins.removeAttrs easy-ps ["buildInputs"]  

Then, to test this out, I run:

nix-shell -p purty

… and I get a “Segmentation fault: 11”

Any help?

1 Like

@dstcruz Sorry you are having trouble with this.

I’m not sure why you would be getting a segfault here, however if I were to take a guess, it would be that inputs and shell are doing something weird.

Could you just pull out the attributes that you’re interested in using? (Just purty?)

let
    easy-ps = import (builtins.fetchGit { url = "https://github.com/justinwoo/easy-purescript-nix.git"; }) {};
in
easy-ps.inputs.purty

You’ll have to adapt this slightly for use as an overlay.