summary refs log tree commit diff
path: root/gnu/packages/xdisorg.scm
diff options
context:
space:
mode:
authorSughosha <Sughosha@proton.me>2022-12-19 17:18:33 +0000
committerLudovic Courtès <ludo@gnu.org>2023-01-26 11:11:18 +0100
commit359d33ee404a4e0de5890a6e44ceed5459c076c6 (patch)
tree3722f7fb9b082dc390dec5aee8553eebb91efd36 /gnu/packages/xdisorg.scm
parent4d2e35ebf8ccadd07967578b49a1f71f940ab9f3 (diff)
downloadguix-359d33ee404a4e0de5890a6e44ceed5459c076c6.tar.gz
gnu: Add wl-color-picker.
* gnu/packages/xdisorg.scm (wl-color-picker): New variable.

Co-authored-by: Ludovic Courtès <ludo@gnu.org>
Diffstat (limited to 'gnu/packages/xdisorg.scm')
-rw-r--r--gnu/packages/xdisorg.scm43
1 files changed, 43 insertions, 0 deletions
diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 10518094e3..f6f015732d 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -113,6 +113,7 @@
   #:use-module (gnu packages haskell-xyz)
   #:use-module (gnu packages icu4c)
   #:use-module (gnu packages image)
+  #:use-module (gnu packages imagemagick)
   #:use-module (gnu packages kde-frameworks)
   #:use-module (gnu packages libbsd)
   #:use-module (gnu packages libevent)
@@ -2471,6 +2472,48 @@ binary to setuid-binaries:
 @end example")
     (license license:asl2.0)))
 
+(define-public wl-color-picker
+  (package
+    (name "wl-color-picker")
+    (version "1.3")
+    (home-page "https://github.com/jgmdev/wl-color-picker")
+    (source (origin
+              (method git-fetch)
+              (uri (git-reference
+                    (url home-page)
+                    (commit (string-append "v" version))))
+              (file-name (git-file-name name version))
+              (sha256
+               (base32
+                "0h5b8qfwri7a1invk8dran3436ac37x6r8fic3l5cxqj5rgnky4n"))))
+    (build-system copy-build-system)
+    (arguments
+     `(#:install-plan '(("wl-color-picker.sh" "bin/wl-color-picker")
+                        ("wl-color-picker.png" "share/pixmaps/")
+                        ("wl-color-picker.svg"
+                         "share/icons/hicolor/scalable/apps/")
+                        ("wl-color-picker.desktop" "share/applications/"))
+       #:phases (modify-phases %standard-phases
+                  (add-after 'install 'wrap-script
+                    (lambda* (#:key outputs #:allow-other-keys)
+                      (wrap-program (string-append (assoc-ref outputs "out")
+                                                   "/bin/wl-color-picker")
+                                    `("PATH" =
+                                      (,(getenv "PATH")))))))))
+    (inputs (list coreutils-minimal
+                  bash-minimal
+                  grim
+                  hicolor-icon-theme
+                  imagemagick
+                  slurp
+                  wl-clipboard
+                  zenity))
+    (synopsis "Wayland color picker")
+    (description
+     "@command{wl-color-picker} is a script that provides color picker for
+Wayland and @code{wlroots} by leveraging @command{grim} and @command{slurp}.")
+    (license license:expat)))
+
 (define-public wl-clipboard
   (package
     (name "wl-clipboard")