about summary refs log tree commit diff
path: root/pkgs/applications/editors
diff options
context:
space:
mode:
authorSandro <sandro.jaeckel@gmail.com>2021-10-26 16:07:34 +0200
committerGitHub <noreply@github.com>2021-10-26 16:07:34 +0200
commit2c878566309fce5c3f9262a7acfee6aa1c24b7fc (patch)
treeb30df3780442bfbbff648ad62684812fb082f173 /pkgs/applications/editors
parentda12fc6d9d80d9a1259b8cf55ae0abcc31020719 (diff)
parent03023512770f49b45fe871f94c9f9cb7212911f7 (diff)
Merge pull request #142806 from WolfangAukang/thiefmd
Diffstat (limited to 'pkgs/applications/editors')
-rw-r--r--pkgs/applications/editors/thiefmd/default.nix48
1 files changed, 48 insertions, 0 deletions
diff --git a/pkgs/applications/editors/thiefmd/default.nix b/pkgs/applications/editors/thiefmd/default.nix
new file mode 100644
index 0000000000000..81222ff82f101
--- /dev/null
+++ b/pkgs/applications/editors/thiefmd/default.nix
@@ -0,0 +1,48 @@
+{ lib, stdenv, fetchFromGitHub, wrapGAppsHook, cmake, desktop-file-utils, glib
+, meson, ninja, pkg-config, vala, clutter, discount, gtk3, gtksourceview4, gtkspell3
+, libarchive, libgee, libhandy, libsecret, link-grammar, webkitgtk }:
+
+stdenv.mkDerivation rec {
+  pname = "thiefmd";
+  version = "0.2.4";
+
+  src = fetchFromGitHub {
+    owner = "kmwallio";
+    repo = "ThiefMD";
+    rev = "v${version}-easypdf";
+    sha256 = "sha256-YN17o6GtpulxhXs+XYZLY36g9S8ggR6URNLrjs5PEoI=";
+    fetchSubmodules = true;
+  };
+
+  nativeBuildInputs = [
+    cmake desktop-file-utils glib meson wrapGAppsHook
+    ninja pkg-config vala
+  ];
+
+  buildInputs = [
+    clutter discount gtk3 gtksourceview4 gtkspell3
+    libarchive libgee libhandy libsecret link-grammar
+    webkitgtk
+  ];
+
+  dontUseCmakeConfigure = true;
+
+  postInstall = ''
+    mv $out/share/applications/com.github.kmwallio.thiefmd.desktop \
+      $out/share/applications/thiefmd.desktop
+    substituteInPlace $out/share/applications/thiefmd.desktop \
+      --replace 'Exec=com.github.kmwallio.' Exec=$out/bin/
+
+    makeWrapper $out/bin/com.github.kmwallio.thiefmd \
+      $out/bin/thiefmd \
+      --prefix XDG_DATA_DIRS : "${gtk3}/share/gsettings-schemas/${gtk3.name}/"
+  '';
+
+  meta = with lib; {
+    description = "Markdown & Fountain editor that helps with organization and management";
+    homepage = "https://thiefmd.com";
+    license = licenses.gpl3Only;
+    platforms = platforms.linux;
+    maintainers = with maintainers; [ wolfangaukang ];
+  };
+}