about summary refs log tree commit diff
path: root/pkgs/by-name/sy/syncthing-tray/package.nix
diff options
context:
space:
mode:
Diffstat (limited to 'pkgs/by-name/sy/syncthing-tray/package.nix')
-rw-r--r--pkgs/by-name/sy/syncthing-tray/package.nix44
1 files changed, 44 insertions, 0 deletions
diff --git a/pkgs/by-name/sy/syncthing-tray/package.nix b/pkgs/by-name/sy/syncthing-tray/package.nix
new file mode 100644
index 0000000000000..2fc912de8519d
--- /dev/null
+++ b/pkgs/by-name/sy/syncthing-tray/package.nix
@@ -0,0 +1,44 @@
+{
+  lib,
+  fetchFromGitHub,
+  fetchpatch,
+  buildGoModule,
+  pkg-config,
+  libappindicator-gtk3,
+}:
+
+buildGoModule rec {
+  pname = "syncthing-tray";
+  version = "0.7";
+
+  src = fetchFromGitHub {
+    owner = "alex2108";
+    repo = "syncthing-tray";
+    rev = "v${version}";
+    sha256 = "0869kinnsfzb8ydd0sv9fgqsi1sy5rhqg4whfdnrv82xjc71xyw3";
+  };
+
+  vendorHash = "sha256-hGV5bivDUFEbOwU9sU+Eu5Wzz/aZtj6NUkpzHlmZTtw=";
+
+  patches = [
+    # Migrate to Go modules
+    (fetchpatch {
+      url = "https://github.com/alex2108/syncthing-tray/commit/94fac974a227cd03c566f81797a21b1bcc29adf5.patch";
+      hash = "sha256-uJfnI9kGIlw4OzFoML+ulgR3keOeVB3+ox/4RtYJNXY=";
+    })
+  ];
+
+  nativeBuildInputs = [ pkg-config ];
+  buildInputs = [ libappindicator-gtk3 ];
+
+  meta = {
+    description = "Simple application tray for syncthing";
+    homepage = "https://github.com/alex2108/syncthing-tray";
+    license = lib.licenses.mit;
+    maintainers = with lib.maintainers; [
+      luftmensch-luftmensch
+      nickhu
+    ];
+    mainProgram = "syncthing-tray";
+  };
+}