about summary refs log tree commit diff
path: root/pkgs/applications/misc/citations
diff options
context:
space:
mode:
authorBenedikt Broich <b.broich@posteo.de>2022-12-13 19:37:27 +0100
committerBenedikt Broich <b.broich@posteo.de>2022-12-13 19:37:27 +0100
commit9cea14567fc63dc38c2cf9e3318e85b3adaee1e1 (patch)
tree8e8f843428f6fb3ef7424c17561a67093af7ff5e /pkgs/applications/misc/citations
parentd474f8888421150b506d813851f557f579d8346b (diff)
citations: init at 0.5.1
Diffstat (limited to 'pkgs/applications/misc/citations')
-rw-r--r--pkgs/applications/misc/citations/default.nix74
1 files changed, 74 insertions, 0 deletions
diff --git a/pkgs/applications/misc/citations/default.nix b/pkgs/applications/misc/citations/default.nix
new file mode 100644
index 0000000000000..928978ef47f4f
--- /dev/null
+++ b/pkgs/applications/misc/citations/default.nix
@@ -0,0 +1,74 @@
+{ darwin
+, desktop-file-utils
+, fetchFromGitLab
+, gettext
+, glib
+, gtk4
+, gtksourceview5
+, lib
+, libadwaita
+, meson
+, ninja
+, pkg-config
+, poppler
+, rustPlatform
+, stdenv
+, testers
+, wrapGAppsHook4
+}:
+stdenv.mkDerivation (finalAttrs: {
+  pname = "citations";
+  version = "0.5.1";
+
+  src = fetchFromGitLab {
+    domain = "gitlab.gnome.org";
+    owner = "World";
+    repo = finalAttrs.pname;
+    rev = finalAttrs.version;
+    hash = "sha256-QPK6Nw0tDdttUDFKMgThTYMTxGXsn5OReqf1LNAai7g=";
+  };
+
+  cargoDeps = rustPlatform.fetchCargoTarball {
+    src = finalAttrs.src;
+    name = "${finalAttrs.pname}-${finalAttrs.version}";
+    hash = "sha256-Kounxi4JxoU4+rWMWNB8rzTyG3MDKYD0OzYfAHwm6bY=";
+  };
+
+  nativeBuildInputs = [
+    desktop-file-utils
+    gettext
+    glib
+    meson
+    ninja
+    pkg-config
+    rustPlatform.cargoSetupHook
+    rustPlatform.rust.cargo
+    rustPlatform.rust.rustc
+    wrapGAppsHook4
+  ];
+
+  buildInputs = [
+    glib
+    gtk4
+    gtksourceview5
+    libadwaita
+    poppler
+  ] ++ lib.optional stdenv.isDarwin [
+    darwin.apple_sdk.frameworks.Foundation
+  ];
+
+  doCheck = true;
+
+  passthru.tests.version = testers.testVersion {
+    package = finalAttrs.finalPackage;
+    command = "citations --help";
+  };
+
+  meta = with lib; {
+    description = "Manage your bibliographies using the BibTeX format";
+    homepage = "https://apps.gnome.org/app/org.gnome.World.Citations";
+    license = licenses.gpl3Plus;
+    maintainers = with maintainers; [ benediktbroich ];
+    platforms = platforms.unix;
+  };
+})