Hello,

I'm using nix-shell to setup a Haskell environment for development.  On a
project I ran into a problem recently, and I'm curious if there is a
common/preferred way of solving it.

The problem I ran into is that the project depends on the mongoDB 1.5
package.  The API changed drastically in 2.0 and we're not ready to
undertake the upgrade yet.  I think I can handle this by creating a nixpkgs
directory in the project, putting a mongoDB/default.nix file in there that
is setup for the version we need, then override it in our shell.nix file
like this:

let

   pkgs = import <nixpkgs> {};

   haskellPackages = pkgs.haskellPackages.override {

     extension = self: super: {
       mongoDB = self.callPackage nixpkgs/mongoDB {};
       ourkidsclass = self.callPackage ./. {};

     };

   };

Is this a reasonable approach? Is there a better way?

Thanks,
Rich
_______________________________________________
nix-dev mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-dev

Reply via email to