11 stdenv.mkDerivation (finalAttrs: {
12 pname = "node-hp-scan-to";
15 src = fetchFromGitHub {
17 repo = "node-hp-scan-to";
18 rev = "v${finalAttrs.version}";
19 hash = "sha256-/XUqCL2F1iMYUoCbGgL9YKs+8wIFHvmh2O0LMbDU8yE=";
22 offlineCache = fetchYarnDeps {
23 yarnLock = "${finalAttrs.src}/yarn.lock";
24 hash = "sha256-pxeYumHuomOFyCi8XhYTYQNcsGOUvjOg36bFD0yhdLk=";
37 export HOME=$(mktemp -d)
38 yarn config --offline set yarn-offline-mirror $offlineCache
39 fixup-yarn-lock yarn.lock
40 yarn --offline --frozen-lockfile --ignore-platform --ignore-scripts --no-progress --non-interactive install
41 patchShebangs node_modules
57 yarn --offline --production install
59 mkdir -p "$out/lib/node_modules/node-hp-scan-to"
60 cp -r dist node_modules package.json "$out/lib/node_modules/node-hp-scan-to"
62 makeWrapper "${nodejs}/bin/node" "$out/bin/node-hp-scan-to" \
63 --add-flags "$out/lib/node_modules/node-hp-scan-to/dist/index.js"
69 changelog = "https://github.com/manuc66/node-hp-scan-to/releases/tag/${finalAttrs.src.rev}";
70 description = "Allow to send scan from device to computer for some HP All-in-One Printers";
71 homepage = "https://github.com/manuc66/node-hp-scan-to";
72 license = lib.licenses.mit;
73 mainProgram = "node-hp-scan-to";
74 maintainers = with lib.maintainers; [ jonas-w ];