anytype: use finalAttrs

+6 -10
+6 -10
pkgs/by-name/an/anytype/package.nix
··· 12 12 commandLineArgs ? "", 13 13 }: 14 14 15 - let 15 + buildNpmPackage (finalAttrs: { 16 16 pname = "anytype"; 17 17 version = "0.49.2"; 18 18 19 19 src = fetchFromGitHub { 20 20 owner = "anyproto"; 21 21 repo = "anytype-ts"; 22 - tag = "v${version}"; 22 + tag = "v${finalAttrs.version}"; 23 23 hash = "sha256-8+x2FmyR5x9Zrm3t71RSyxAKcJCvnR98+fqHXjBE7aU="; 24 24 }; 25 - description = "P2P note-taking tool"; 26 25 27 26 locales = fetchFromGitHub { 28 27 owner = "anyproto"; ··· 30 29 rev = "873b42df7320ebbbc80d7e2477914dac70363ef7"; 31 30 hash = "sha256-Mr0KfXn9NO86QqgBhVjSs2przN/GtjuhJHJ9djo8Feg="; 32 31 }; 33 - in 34 - buildNpmPackage { 35 - inherit pname version src; 36 32 37 33 npmDepsHash = "sha256-fuNTSZl+4DG/YL34f/+bYK26ruRFAc1hyHVAm256LiE="; 38 34 ··· 62 58 cp -r ${anytype-heart}/lib dist/ 63 59 cp -r ${anytype-heart}/bin/anytypeHelper dist/ 64 60 65 - for lang in ${locales}/locales/*; do 61 + for lang in ${finalAttrs.locales}/locales/*; do 66 62 cp "$lang" "dist/lib/json/lang/$(basename $lang)" 67 63 done 68 64 ··· 106 102 exec = "anytype %U"; 107 103 icon = "anytype"; 108 104 desktopName = "Anytype"; 109 - comment = description; 105 + comment = finalAttrs.meta.description; 110 106 mimeTypes = [ "x-scheme-handler/anytype" ]; 111 107 categories = [ 112 108 "Utility" ··· 119 115 ]; 120 116 121 117 meta = { 122 - inherit description; 118 + description = "P2P note-taking tool"; 123 119 homepage = "https://anytype.io/"; 124 120 license = lib.licenses.unfreeRedistributable; 125 121 mainProgram = "anytype"; ··· 136 132 ]; 137 133 broken = stdenv.hostPlatform.isDarwin; 138 134 }; 139 - } 135 + })