Loads pnpm
’s shrinkwrap.yaml into nix expressions.
with (import <nixpkgs> {});
with (import /path/to/pnpm2nix { inherit pkgs; });
mkPnpmPackage {
src = ./.;
# These default to src/package.json & src/shrinkwrap.yaml
# packageJSON = ./package.json;
# shrinkwrapYML = ./shrinkwrap.yaml;
}
More comprehensive examples can be found in the tests.
with (import <nixpkgs> {});
with (import /path/to/pnpm2nix { inherit pkgs; });
mkPnpmPackage {
src = ./.;
}
with (import <nixpkgs> {});
with (import /path/to/pnpm2nix { inherit pkgs; });
mkShell {
buildInputs = [
(mkPnpmEnv (import ./default.nix))
];
}
pnpm does not currently include checksums for tarballs
Until this is fixed in pnpm
github dependencies won’t work unless you opt in to impure builds.
This is currently pre-alpha software, it might eat your kittens.
pnpm2nix
is released under the terms of the MIT license.