From 12eb625292c052d6e3d3dd2782ee7bc965389751 Mon Sep 17 00:00:00 2001 From: "P. R. d. O" Date: Wed, 27 Oct 2021 13:35:52 -0600 Subject: [PATCH] markmind: init at 1.3.1 --- pkgs/applications/misc/markmind/default.nix | 48 +++++++++++++++++++++ pkgs/top-level/all-packages.nix | 4 ++ 2 files changed, 52 insertions(+) create mode 100644 pkgs/applications/misc/markmind/default.nix diff --git a/pkgs/applications/misc/markmind/default.nix b/pkgs/applications/misc/markmind/default.nix new file mode 100644 index 000000000000..e44b7fe54ad5 --- /dev/null +++ b/pkgs/applications/misc/markmind/default.nix @@ -0,0 +1,48 @@ +{ lib, stdenv, fetchurl, appimageTools, makeWrapper, electron }: + +stdenv.mkDerivation rec { + pname = "markmind"; + version = "1.3.1"; + + src = fetchurl { + url = "https://github.com/MarkMindCkm/Mark-Mind/releases/download/v${version}/Mark.Mind-${version}.AppImage"; + sha256 = "sha256-iOJ0IOIzleA69rv94Qd35rMbHc+XSi8OPatf2V6sYrI="; + }; + + appimageContents = appimageTools.extractType2 { + name = "markmind-${version}"; + inherit src; + }; + + dontUnpack = true; + dontConfigure = true; + dontBuild = true; + + nativeBuildInputs = [ makeWrapper ]; + + installPhase = '' + runHook preInstall + + mkdir -p $out/bin $out/share/markmind $out/share/applications + cp -a ${appimageContents}/{locales,resources} $out/share/markmind + cp -a ${appimageContents}/mind.desktop $out/share/applications/markmind.desktop + cp -a ${appimageContents}/usr/share/icons $out/share + substituteInPlace $out/share/applications/markmind.desktop \ + --replace 'Exec=AppRun' 'Exec=markmind' + + runHook postInstall + ''; + + postFixup = '' + makeWrapper ${electron}/bin/electron $out/bin/markmind \ + --add-flags $out/share/markmind/resources/app.asar + ''; + + meta = with lib; { + description = "Mind map and outliner editor"; + homepage = "https://github.com/MarkMindCkm/Mark-Mind"; + license = licenses.mit; + maintainers = with maintainers; [ wolfangaukang ]; + platforms = [ "x86_64-linux" ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index d6ef1ba05e02..05ae453ff6b9 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -26351,6 +26351,10 @@ with pkgs; markets = callPackage ../applications/misc/markets { }; + markmind = callPackage ../applications/misc/markmind { + electron = electron_9; + }; + marp = callPackage ../applications/office/marp { }; magnetico = callPackage ../applications/networking/p2p/magnetico { };