asar: remove mkYarnPackage usage

+13 -84
-62
pkgs/by-name/as/asar/package.json
··· 1 - { 2 - "name": "@electron/asar", 3 - "description": "Creating Electron app packages", 4 - "version": "0.0.0-development", 5 - "main": "./lib/asar.js", 6 - "types": "./lib/index.d.ts", 7 - "bin": { 8 - "asar": "./bin/asar.js" 9 - }, 10 - "files": [ 11 - "bin", 12 - "lib", 13 - "lib/index.d.ts" 14 - ], 15 - "engines": { 16 - "node": ">=10.12.0" 17 - }, 18 - "license": "MIT", 19 - "homepage": "https://github.com/electron/asar", 20 - "repository": { 21 - "type": "git", 22 - "url": "https://github.com/electron/asar.git" 23 - }, 24 - "bugs": { 25 - "url": "https://github.com/electron/asar/issues" 26 - }, 27 - "scripts": { 28 - "mocha": "xvfb-maybe electron-mocha --reporter spec && mocha --reporter spec", 29 - "test": "npm run lint && npm run mocha", 30 - "lint": "tsd && standard", 31 - "standard": "standard", 32 - "tsd": "tsd" 33 - }, 34 - "standard": { 35 - "env": { 36 - "mocha": true 37 - }, 38 - "globals": [ 39 - "BigInt" 40 - ] 41 - }, 42 - "tsd": { 43 - "directory": "test" 44 - }, 45 - "dependencies": { 46 - "chromium-pickle-js": "^0.2.0", 47 - "commander": "^5.0.0", 48 - "glob": "^7.1.6", 49 - "minimatch": "^3.0.4" 50 - }, 51 - "devDependencies": { 52 - "@continuous-auth/semantic-release-npm": "^3.0.0", 53 - "electron": "^22.0.0", 54 - "electron-mocha": "^11.0.2", 55 - "lodash": "^4.17.15", 56 - "mocha": "^10.1.0", 57 - "rimraf": "^3.0.2", 58 - "standard": "^14.3.3", 59 - "tsd": "^0.25.0", 60 - "xvfb-maybe": "^0.2.1" 61 - } 62 - }
···
+13 -22
pkgs/by-name/as/asar/package.nix
··· 1 { 2 lib, 3 - mkYarnPackage, 4 fetchFromGitHub, 5 fetchYarnDeps, 6 }: 7 8 - mkYarnPackage rec { 9 pname = "asar"; 10 version = "3.2.4"; 11 12 src = fetchFromGitHub { 13 owner = "electron"; 14 repo = "asar"; 15 - rev = "v${version}"; 16 hash = "sha256-12FP8VRDo1PQ+tiN4zhzkcfAx9zFs/0MU03t/vFo074="; 17 }; 18 19 - packageJSON = ./package.json; 20 - 21 offlineCache = fetchYarnDeps { 22 - yarnLock = "${src}/yarn.lock"; 23 hash = "sha256-/fV3hd98pl46+fgmiMH9sDQrrZgdLY1oF9c3TaIxRSg="; 24 }; 25 26 - doDist = false; 27 - 28 - installPhase = '' 29 - runHook preInstall 30 - 31 - mkdir -p "$out/lib/node_modules" 32 - mv deps/@electron "$out/lib/node_modules" 33 - rm "$out/lib/node_modules/@electron/asar/node_modules" 34 - mv node_modules "$out/lib/node_modules/@electron/asar" 35 - 36 - mkdir "$out/bin" 37 - ln -s "$out/lib/node_modules/@electron/asar/bin/asar.js" "$out/bin/asar" 38 - 39 - runHook postInstall 40 - ''; 41 42 meta = { 43 description = "Simple extensive tar-like archive format with indexing"; ··· 46 mainProgram = "asar"; 47 maintainers = with lib.maintainers; [ xvapx ]; 48 }; 49 - }
··· 1 { 2 lib, 3 + stdenv, 4 fetchFromGitHub, 5 fetchYarnDeps, 6 + yarnConfigHook, 7 + yarnInstallHook, 8 + nodejs, 9 }: 10 11 + stdenv.mkDerivation (finalAttrs: { 12 pname = "asar"; 13 version = "3.2.4"; 14 15 src = fetchFromGitHub { 16 owner = "electron"; 17 repo = "asar"; 18 + tag = "v${finalAttrs.version}"; 19 hash = "sha256-12FP8VRDo1PQ+tiN4zhzkcfAx9zFs/0MU03t/vFo074="; 20 }; 21 22 offlineCache = fetchYarnDeps { 23 + yarnLock = "${finalAttrs.src}/yarn.lock"; 24 hash = "sha256-/fV3hd98pl46+fgmiMH9sDQrrZgdLY1oF9c3TaIxRSg="; 25 }; 26 27 + nativeBuildInputs = [ 28 + yarnConfigHook 29 + yarnInstallHook 30 + nodejs 31 + ]; 32 33 meta = { 34 description = "Simple extensive tar-like archive format with indexing"; ··· 37 mainProgram = "asar"; 38 maintainers = with lib.maintainers; [ xvapx ]; 39 }; 40 + })