mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-09-13 02:39:58 +00:00
62 lines
1.2 KiB
Nix
62 lines
1.2 KiB
Nix
{
|
|
lib,
|
|
stdenv,
|
|
fetchFromGitHub,
|
|
fetchPnpmDeps,
|
|
nodejs,
|
|
pnpm_10,
|
|
pnpmConfigHook,
|
|
nix-update-script,
|
|
}:
|
|
let
|
|
pnpm = pnpm_10;
|
|
in
|
|
stdenv.mkDerivation (finalAttrs: {
|
|
pname = "postcss";
|
|
version = "8.5.26";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "postcss";
|
|
repo = "postcss";
|
|
tag = finalAttrs.version;
|
|
hash = "sha256-60q20REE9bE6lgTDW+Eoq2bsIJu+915FMwnAjSHjtf8=";
|
|
};
|
|
|
|
nativeBuildInputs = [
|
|
nodejs
|
|
pnpmConfigHook
|
|
pnpm
|
|
];
|
|
|
|
pnpmDeps = fetchPnpmDeps {
|
|
inherit (finalAttrs) pname version src;
|
|
inherit pnpm;
|
|
fetcherVersion = 3;
|
|
hash = "sha256-9VpQzRWymMBB/ThJBTKPUFIgfPyWf3EiFE7z+bpWcXg=";
|
|
};
|
|
|
|
dontBuild = true;
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
rm -rf node_modules
|
|
pnpm install --production --offline --force
|
|
mkdir -p $out/lib/node_modules/postcss
|
|
mv ./* $out/lib/node_modules/postcss
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
passthru.updateScript = nix-update-script { };
|
|
|
|
meta = {
|
|
changelog = "https://github.com/postcss/postcss/releases/tag/${finalAttrs.version}";
|
|
description = "Transforming styles with JS plugins";
|
|
homepage = "https://postcss.org/";
|
|
license = lib.licenses.mit;
|
|
maintainers = [ ];
|
|
platforms = lib.platforms.all;
|
|
};
|
|
})
|