[PATCH] gnu: Add clipman.

  • Done
  • quality assurance status badge
Details
2 participants
  • Wamm K. D
  • Christopher Baines
Owner
unassigned
Submitted by
Wamm K. D
Severity
normal

Debbugs page

Wamm K. D wrote 2 years ago
(address . guix-patches@gnu.org)(name . Wamm K. D)(address . jaft.r@outlook.com)
BY5PR07MB7029701B0EBD53B4C8DEAE3C99C39@BY5PR07MB7029.namprd07.prod.outlook.com
* gnu/packages/xdisorg.scm (clipman): New variable.
---
I propogated =wl-clipboard= as the user needs access to ~wl-paste~ in order to
initialize the daemon.

gnu/packages/xdisorg.scm | 42 ++++++++++++++++++++++++++++++++++++++++
1 file changed, 42 insertions(+)

Toggle diff (76 lines)
diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 10edfc7379..3ba695fca1 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -77,6 +77,7 @@ (define-module (gnu packages xdisorg)
#:use-module (guix build-system cmake)
#:use-module (guix build-system copy)
#:use-module (guix build-system glib-or-gtk)
+ #:use-module (guix build-system go)
#:use-module (guix build-system gnu)
#:use-module (guix build-system meson)
#:use-module (guix build-system python)
@@ -107,6 +108,7 @@ (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 gnome)
#:use-module (gnu packages gtk)
#:use-module (gnu packages guile)
@@ -127,6 +129,7 @@ (define-module (gnu packages xdisorg)
#:use-module (gnu packages python-xyz)
#:use-module (gnu packages qt)
#:use-module (gnu packages sphinx)
+ #:use-module (gnu packages syncthing)
#:use-module (gnu packages tcl)
#:use-module (gnu packages terminals)
#:use-module (gnu packages xml)
@@ -2893,6 +2896,45 @@ (define-public clipmenu
After selection, the clip is put onto the PRIMARY and CLIPBOARD X selections.")
(license license:public-domain))))
+(define-public clipman
+ (package
+ (name "clipman")
+ (version "1.6.1")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url (string-append "https://github.com/yory8/" name "/"))
+ (commit (string-append "v" version))))
+ (sha256 (base32
+ "0b9kvj0dif4221dy6c1npknhhjxvbc4kygzhwxjirpwjws0yv6v9"))))
+ (build-system go-build-system)
+ (arguments
+ (list #:import-path "github.com/yory8/clipman"
+ #:phases #~(modify-phases %standard-phases
+ (add-before 'build 'fix-something
+ (lambda _
+ (substitute* "src/github.com/yory8/clipman/main.go"
+ (("gopkg.in/alecthomas/kingpin.v2")
+ "github.com/alecthomas/kingpin"))))
+ (delete 'install-license-files))))
+ (native-inputs (list go-github-com-alecthomas-template
+ go-github-com-alecthomas-units))
+ (inputs (list go-github-com-kballard-go-shellquote
+ go-github-com-alecthomas-kingpin
+ libnotify))
+ (propagated-inputs (list wl-clipboard))
+ (synopsis "Basic clipboard manager with support for persisting copy buffers")
+ (description
+ "A clipboard manager for Wayland that relies on an external selector,
+such as @code{wofi}, @code{bemenu}, @code{dmenu}, or @code{rofi}.
+
+Run the binary in your session by adding @command{exec wl-paste -t text --watch
+clipman store} (or @command{exec wl-paste -t text --watch clipman store 1>>
+PATH/TO/LOGFILE 2>&1 &} to log errors) at the beginning of wherever you
+initialize programs.")
+ (home-page "https://github.com/yory8/clipman")
+ (license license:gpl3)))
+
(define-public kbdd
(package
(name "kbdd")
--
2.38.1
Christopher Baines wrote 2 years ago
(name . Wamm K. D)(address . jaft.r@outlook.com)(address . 60806-done@debbugs.gnu.org)(address . guix-patches@gnu.org)
87lekwl0a1.fsf@cbaines.net
"Wamm K. D" <jaft.r@outlook.com> writes:

Toggle quote (8 lines)
> * gnu/packages/xdisorg.scm (clipman): New variable.
> ---
> I propogated =wl-clipboard= as the user needs access to ~wl-paste~ in order to
> initialize the daemon.
>
> gnu/packages/xdisorg.scm | 42 ++++++++++++++++++++++++++++++++++++++++
> 1 file changed, 42 insertions(+)

I've gone ahead and pushed this to master as
c3dd743b9a7bc9bb72718957680dfe9a618cb138.

I added #:install-source? #f to the arguments to avoid including the
source code in the output as this seems unnecessary. I've also added a
bit to use an absolute filename for wl-copy since that means that the
propagated input can be avoided.

Thanks,

Chris
-----BEGIN PGP SIGNATURE-----

iQKlBAEBCgCPFiEEPonu50WOcg2XVOCyXiijOwuE9XcFAmPvrFZfFIAAAAAALgAo
aXNzdWVyLWZwckBub3RhdGlvbnMub3BlbnBncC5maWZ0aGhvcnNlbWFuLm5ldDNF
ODlFRUU3NDU4RTcyMEQ5NzU0RTBCMjVFMjhBMzNCMEI4NEY1NzcRHG1haWxAY2Jh
aW5lcy5uZXQACgkQXiijOwuE9XeoMA//SHfd75zw8va81oZ4/okLvQadSe6MBv6t
guDk635ImaHKfuFS0H2itcV+SEDv2biIxyiYOERNkWKBhn9XMd0fclyGrW8Rr7tE
med9vdHuxsAFFSFtMhVV1VTNKj3ffFQcVw2zQTvIDcUTjQQVMbBdmv+zGU1PFmo1
mgZxGdg86t3p9eUurCDvOxYnGqNwrB4t+Ir1/9zRwJlkECI1HxGKOipEV+8KWLtX
bgov9xZf2q0LmADmSrdPrT19GgpYXq16xujDWbvtG+w2N9xJ9ZGq1Gud9TihAgJV
CeH2nuqmKcZ++tA2UM52XJBUgoWEMDzliqUP0bhBNb7AoFYIR2GNLiZV2EzsjVkA
/HoRuA+KLyytTFjLC2iJfsUIkD56IwlR1UOGUIGQM46sbPWw+0n4lw/IXrh/pbK7
fzwY07G22NEfzLoEArPetb6nzKKpBgfDV/Ca1qVcQVhS1cdQRMwyaoS8eAGapk9e
j3TPe8eYBbFVrccGJQzu00pOeBXGxJ4S0f8XAU+TUnEfeAAOlN+1JcgjTGrk0xpt
NWndbNI2ZzqeHs+s+L2U2Jv0ZmSOKkbRVz2wbCkj6h5PDl2BN+3raWtKRxXll3lb
R1msJLGlXnb9ZakxNKOAyIVhwop6TQhDOz66K2ZDY9jQeRU+BCK5ASU/HwjsEG2o
6f2awpKTwKo=
=u4lu
-----END PGP SIGNATURE-----

Jaft wrote 2 years ago
(name . mail@cbaines.net)(address . mail@cbaines.net)(name . 60806-done@debbugs.gnu.org)(address . 60806-done@debbugs.gnu.org)
BY5PR07MB7029FCD598D2AB33CED42CB899A89@BY5PR07MB7029.namprd07.prod.outlook.com
Toggle quote (3 lines)
> I've also added a bit to use an absolute filename for wl-copy since that means that the
> propagated input can be avoided.

I don't know how much it matters but I specified "wl-paste", not "wl-copy", because the user is expected to run "wl-paste -t text --watch clipman store" (or similar) themselves, independent of the "clipman" executable.

Not propagating the input means they'd have to install "wl-clipboard" in addition to "clipman" to be able to get the clipboard daemon running which could feasibly mean running different "wl-clipboard" executables than the ones that the "clipman" executables are using.

Like I said, that could be fine and my uncertainty about whether it matters not relevant but just wanted to call it out, just in case.
Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 60806@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 60806
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help