43 lines
649 B
Nix
43 lines
649 B
Nix
{
|
|
lib,
|
|
nodejs,
|
|
pnpm,
|
|
stdenv,
|
|
}:
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
pname = "chicken-box";
|
|
version = "dev";
|
|
|
|
src = lib.cleanSource ./.;
|
|
|
|
nativeBuildInputs = [
|
|
nodejs
|
|
pnpm.configHook
|
|
];
|
|
|
|
pnpmDeps = pnpm.fetchDeps {
|
|
inherit (finalAttrs) pname version src;
|
|
hash = "sha256-uk28bfbSRLTLaOanIGAHECAcLdQG4lbHIwmtzbkfkA0=";
|
|
};
|
|
|
|
buildPhase = ''
|
|
runHook preBuild
|
|
|
|
pnpm build
|
|
|
|
runHook postBuild
|
|
'';
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
cp -r ./dist $out
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
meta = {
|
|
homepage = "https://git.ny4.dev/nyancat/chicken-box";
|
|
license = lib.licenses.mit;
|
|
};
|
|
})
|