From: Spencer Peters <spencerpeters@protonmail.com>
      * gnu/packages/xdisorg.scm (cliphist): New variable.

Change-Id: I33d71b9739158101638b66827592d1c3cbb1b443
---
 gnu/packages/xdisorg.scm | 38 ++++++++++++++++++++++++++++++++++++++
 1 file changed, 38 insertions(+)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 4c12835b24..cdd196e35d 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -63,6 +63,7 @@
 ;;; Copyright © 2022 Mehmet Tekman <mtekman89@gmail.com>
 ;;; Copyright © 2024 Artyom V. Poptsov <poptsov.artyom@gmail.com>
 ;;; Copyright © 2024 Igor Goryachev <igor@goryachev.org>
+;;; Copyright © 2024 Spencer Peters <spencerpeters@protonmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -116,6 +117,8 @@ (define-module (gnu packages xdisorg)
   #:use-module (gnu packages gl)
   #:use-module (gnu packages gl)
   #:use-module (gnu packages glib)
+  #:use-module (gnu packages golang)
+  #:use-module (gnu packages golang-build)
   #:use-module (gnu packages golang-xyz)
   #:use-module (gnu packages gnome)
   #:use-module (gnu packages gtk)
@@ -3852,3 +3855,38 @@ (define-public xxkb
 accepts events from XKB.  That means that it will work with the existing
 setup of your X Server without any modifications.")
     (license license:artistic2.0)))
+
+(define-public cliphist
+  (package
+    (name "cliphist")
+    (version "0.5.0")
+    (source
+     (origin
+       (method git-fetch)
+       (uri (git-reference
+             (url "https://github.com/sentriz/cliphist")
+             (commit (string-append "v" version))))
+       (file-name (git-file-name name version))
+       (sha256
+        (base32 "1cbhrw9vk8c0in9yyhlp0k9rldgjwbcj00d7vqh69p3igznhdgsk"))))
+    (build-system go-build-system)
+    (arguments
+     (list
+      #:go go-1.22
+      #:import-path "go.senan.xyz/cliphist"))
+    (inputs (list go-github-com-rogpeppe-go-internal
+                  go-go-etcd-io-bbolt
+                  go-go-senan-xyz-flagconf
+                  go-golang-org-x-image
+                  go-golang-org-x-sys
+                  go-golang-org-x-tools
+                  wl-clipboard
+                  xdg-utils))
+    (synopsis "Clipboard history manager for wayland with support for images")
+    (description
+     "A Wayland clipboard history manager.  It can write clipboard changes to a
+history file, recall history with any picker which accepts input from
+stdin (including dmenu, rofi, and wofi), copy and past both images and text,
+and preserve leading and trailing whitespace.")
+    (home-page "https://github.com/sentriz/cliphist")
+    (license license:gpl3)))
--
2.45.2