Merge pull request #209203 from j0lol/notesnook

notesnook: init at 2.5.7

authored by

Sandro and committed by
GitHub
600367d1 57695599

+78
+76
pkgs/applications/misc/notesnook/default.nix
··· 1 + { lib, stdenv, appimageTools, fetchurl, undmg }: 2 + 3 + let 4 + pname = "notesnook"; 5 + version = "2.5.7"; 6 + 7 + inherit (stdenv.hostPlatform) system; 8 + throwSystem = throw "Unsupported system: ${system}"; 9 + 10 + suffix = { 11 + x86_64-linux = "linux_x86_64.AppImage"; 12 + x86_64-darwin = "mac_x64.dmg"; 13 + aarch64-darwin = "mac_arm64.dmg"; 14 + }.${system} or throwSystem; 15 + 16 + src = fetchurl { 17 + url = "https://github.com/streetwriters/notesnook/releases/download/v${version}/notesnook_${suffix}"; 18 + hash = { 19 + x86_64-linux = "sha256-M/59pjhuKF/MOMpT9/qrlThHO0V8e49cfiaWMkEWHNg="; 20 + x86_64-darwin = "sha256-cluIizmweIMU6RIFxoEQ3DYChRVEuVLxrPjwfFfeq1w="; 21 + aarch64-darwin = "sha256-cbBnKrb8poyDL1D+32UrOl3RXt8Msncw440qra9+Gs0="; 22 + }.${system} or throwSystem; 23 + }; 24 + 25 + appimageContents = appimageTools.extractType2 { 26 + inherit pname version src; 27 + }; 28 + 29 + meta = with lib; { 30 + description = "A fully open source & end-to-end encrypted note taking alternative to Evernote."; 31 + longDescription = '' 32 + Notesnook is a free (as in speech) & open source note taking app 33 + focused on user privacy & ease of use. To ensure zero knowledge 34 + principles, Notesnook encrypts everything on your device using 35 + XChaCha20-Poly1305 & Argon2. 36 + ''; 37 + homepage = "https://notesnook.com"; 38 + license = licenses.gpl3Only; 39 + maintainers = with maintainers; [ j0lol ]; 40 + platforms = [ "x86_64-linux" "x86_64-darwin" "aarch64-darwin" ]; 41 + }; 42 + 43 + linux = appimageTools.wrapType2 rec { 44 + inherit pname version src meta; 45 + 46 + profile = '' 47 + export LC_ALL=C.UTF-8 48 + ''; 49 + 50 + multiPkgs = null; # no 32bit needed 51 + extraPkgs = appimageTools.defaultFhsEnvArgs.multiPkgs; 52 + extraInstallCommands = '' 53 + mv $out/bin/{${pname}-${version},${pname}} 54 + install -Dm444 ${appimageContents}/notesnook.desktop -t $out/share/applications 55 + install -Dm444 ${appimageContents}/notesnook.png -t $out/share/pixmaps 56 + substituteInPlace $out/share/applications/notesnook.desktop \ 57 + --replace 'Exec=AppRun --no-sandbox %U' 'Exec=${pname}' 58 + ''; 59 + }; 60 + 61 + darwin = stdenv.mkDerivation { 62 + inherit pname version src meta; 63 + 64 + nativeBuildInputs = [ undmg ]; 65 + 66 + sourceRoot = "Notesnook.app"; 67 + 68 + installPhase = '' 69 + mkdir -p $out/Applications/Notesnook.app 70 + cp -R . $out/Applications/Notesnook.app 71 + ''; 72 + }; 73 + in 74 + if stdenv.isDarwin 75 + then darwin 76 + else linux
+2
pkgs/top-level/all-packages.nix
··· 9874 9874 9875 9875 node2nix = nodePackages.node2nix; 9876 9876 9877 + notesnook = callPackage ../applications/misc/notesnook { }; 9878 + 9877 9879 openipmi = callPackage ../tools/system/openipmi { }; 9878 9880 9879 9881 ox = callPackage ../applications/editors/ox { };