particle-cli: init at 3.35.8

This commit is contained in:
Jess
2025-05-10 12:57:27 +12:00
parent 08e23f26b1
commit f75249b4ae
+47
View File
@@ -0,0 +1,47 @@
{
lib,
buildNpmPackage,
fetchFromGitHub,
udev,
nix-update-script,
}:
buildNpmPackage (finalAttrs: {
pname = "particle-cli";
version = "3.35.8";
src = fetchFromGitHub {
owner = "particle-iot";
repo = "particle-cli";
tag = "v${finalAttrs.version}";
hash = "sha256-t4alWb6W6AHBAsyRGLBTmjB0JpfzKBQ+yt2LESuU7YE=";
};
npmDepsHash = "sha256-FEpj9u0KqQ+yLtwFgahun6AUSolbEiWjWstglD9yyQ8=";
buildInputs = [
udev
];
dontNpmBuild = true;
dontNpmPrune = true;
postPatch = ''
ln -s npm-shrinkwrap.json package-lock.json
'';
postInstall = ''
install -D -t $out/etc/udev/rules.d \
$out/lib/node_modules/particle-cli/assets/50-particle.rules
'';
passthru.updateScript = nix-update-script { };
meta = {
description = "Command Line Interface for Particle Cloud and devices";
homepage = "https://github.com/particle-iot/particle-cli";
maintainers = with lib.maintainers; [ jess ];
mainProgram = "particle";
license = lib.licenses.asl20;
};
})