unofficial mirror of guix-devel@gnu.org 
 help / color / mirror / code / Atom feed
* [PATCH 0/3] 3 packages for my programs
@ 2016-07-22  8:21 Alex Kost
  2016-07-22  8:21 ` [PATCH 1/3] gnu: Add xdpyprobe Alex Kost
                   ` (3 more replies)
  0 siblings, 4 replies; 11+ messages in thread
From: Alex Kost @ 2016-07-22  8:21 UTC (permalink / raw)
  To: guix-devel

Hello, I use these programs all the time, so I think maybe they could be
useful for someone else.  Is it reasonable to add these packages to
Guix?

[PATCH 1/3] gnu: Add xdpyprobe.
[PATCH 2/3] gnu: Add guile-xosd.
[PATCH 3/3] gnu: Add guile-daemon.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [PATCH 1/3] gnu: Add xdpyprobe.
  2016-07-22  8:21 [PATCH 0/3] 3 packages for my programs Alex Kost
@ 2016-07-22  8:21 ` Alex Kost
  2016-07-23 11:06   ` Ludovic Courtès
  2016-07-22  8:21 ` [PATCH 2/3] gnu: Add guile-xosd Alex Kost
                   ` (2 subsequent siblings)
  3 siblings, 1 reply; 11+ messages in thread
From: Alex Kost @ 2016-07-22  8:21 UTC (permalink / raw)
  To: guix-devel

* gnu/packages/xdisorg.scm (xdpyprobe): New variable.
---
 gnu/packages/xdisorg.scm | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)

diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm
index 54545a8..485bbc4 100644
--- a/gnu/packages/xdisorg.scm
+++ b/gnu/packages/xdisorg.scm
@@ -13,6 +13,7 @@
 ;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
 ;;; Copyright © 2016 Leo Famulari <leo@famulari.name>
+;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -913,6 +914,28 @@ demos.  It also acts as a nice screen locker.")
                "http://metadata.ftp-master.debian.org/changelogs/"
                "/main/x/xscreensaver/xscreensaver_5.34-2_copyright")))))
 
+(define-public xdpyprobe
+  (package
+    (name "xdpyprobe")
+    (version "0.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "https://github.com/alezost/" name
+                                  "/releases/download/v" version
+                                  "/" name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                "1h09wd2qcg08rj5hcakvdh9q01hkrj8vxly94ax3ch2x06lm0zq8"))))
+    (build-system gnu-build-system)
+    (inputs
+     `(("libx11" ,libx11)))
+    (home-page "https://github.com/alezost/xdpyprobe")
+    (synopsis "Probe X server for connectivity")
+    (description
+     "Xdpyprobe is a tiny C program whose only purpose is to probe a
+connectivity of the X server running on a particular @code{DISPLAY}.")
+    (license license:gpl3+)))
+
 (define-public rofi
   (package
     (name "rofi")
-- 
2.8.3

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 2/3] gnu: Add guile-xosd.
  2016-07-22  8:21 [PATCH 0/3] 3 packages for my programs Alex Kost
  2016-07-22  8:21 ` [PATCH 1/3] gnu: Add xdpyprobe Alex Kost
@ 2016-07-22  8:21 ` Alex Kost
  2016-07-23 11:06   ` Ludovic Courtès
  2016-07-22  8:21 ` [PATCH 3/3] gnu: Add guile-daemon Alex Kost
  2016-07-23 11:06 ` [PATCH 0/3] 3 packages for my programs Ludovic Courtès
  3 siblings, 1 reply; 11+ messages in thread
From: Alex Kost @ 2016-07-22  8:21 UTC (permalink / raw)
  To: guix-devel

* gnu/packages/guile.scm (guile-xosd): New variable.
---
 gnu/packages/guile.scm | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)

diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm
index 2d8ca0c..9b85016 100644
--- a/gnu/packages/guile.scm
+++ b/gnu/packages/guile.scm
@@ -6,6 +6,7 @@
 ;;; Copyright © 2016 Ricardo Wurmus <rekado@elephly.net>
 ;;; Copyright © 2016 Erik Edrosa <erik.edrosa@gmail.com>
 ;;; Copyright © 2016 Eraim Flashner <efraim@flashner.co.il>
+;;; Copyright © 2016 Alex Kost <alezost@gmail.com>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -50,6 +51,8 @@
   #:use-module (gnu packages sdl)
   #:use-module (gnu packages maths)
   #:use-module (gnu packages image)
+  #:use-module (gnu packages xdisorg)
+  #:use-module (gnu packages xorg)
   #:use-module (guix packages)
   #:use-module (guix download)
   #:use-module (guix git-download)
@@ -1122,4 +1125,33 @@ It currently supports MySQL, Postgres and SQLite3.")
 SQL databases.  This package implements the interface for SQLite.")
     (license gpl2+)))
 
+(define-public guile-xosd
+  (package
+    (name "guile-xosd")
+    (version "0.2")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "https://github.com/alezost/" name
+                                  "/releases/download/v" version
+                                  "/" name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                "1j0b07kycccfslp5n6q0hz7adwc7k41fpzds2dvrly67gavjqljv"))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (inputs
+     `(("guile" ,guile-2.0)
+       ("libx11" ,libx11)
+       ("libxext" ,libxext)
+       ("libxinerama" ,libxinerama)
+       ("xosd" ,xosd)))
+    (home-page "https://github.com/alezost/guile-xosd")
+    (synopsis "XOSD bindings for Guile")
+    (description
+     "Guile-XOSD provides Guile bindings for @code{libxosd},
+@uref{http://sourceforge.net/projects/libxosd/, the X On Screen Display
+library}.")
+    (license gpl3+)))
+
 ;;; guile.scm ends here
-- 
2.8.3

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [PATCH 3/3] gnu: Add guile-daemon.
  2016-07-22  8:21 [PATCH 0/3] 3 packages for my programs Alex Kost
  2016-07-22  8:21 ` [PATCH 1/3] gnu: Add xdpyprobe Alex Kost
  2016-07-22  8:21 ` [PATCH 2/3] gnu: Add guile-xosd Alex Kost
@ 2016-07-22  8:21 ` Alex Kost
  2016-07-23 11:07   ` Ludovic Courtès
  2016-07-23 11:06 ` [PATCH 0/3] 3 packages for my programs Ludovic Courtès
  3 siblings, 1 reply; 11+ messages in thread
From: Alex Kost @ 2016-07-22  8:21 UTC (permalink / raw)
  To: guix-devel

* gnu/packages/guile.scm (guile-daemon): New variable.
---
 gnu/packages/guile.scm | 25 +++++++++++++++++++++++++
 1 file changed, 25 insertions(+)

diff --git a/gnu/packages/guile.scm b/gnu/packages/guile.scm
index 9b85016..acae23e 100644
--- a/gnu/packages/guile.scm
+++ b/gnu/packages/guile.scm
@@ -1154,4 +1154,29 @@ SQL databases.  This package implements the interface for SQLite.")
 library}.")
     (license gpl3+)))
 
+(define-public guile-daemon
+  (package
+    (name "guile-daemon")
+    (version "0.1")
+    (source (origin
+              (method url-fetch)
+              (uri (string-append "https://github.com/alezost/" name
+                                  "/releases/download/v" version
+                                  "/" name "-" version ".tar.gz"))
+              (sha256
+               (base32
+                "1s90h8qhblhhz4ahn3p5d573a24px6cdjq2w311ibpgwnsni4qvq"))))
+    (build-system gnu-build-system)
+    (native-inputs
+     `(("pkg-config" ,pkg-config)))
+    (inputs
+     `(("guile" ,guile-2.0)))
+    (home-page "https://github.com/alezost/guile-daemon")
+    (synopsis "Evaluate code in a running Guile process")
+    (description
+     "Guile-Daemon is a small Guile program that loads your initial
+configuration file, and then reads and evaluates Guile expressions that
+you send to a FIFO file.")
+    (license gpl3+)))
+
 ;;; guile.scm ends here
-- 
2.8.3

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/3] 3 packages for my programs
  2016-07-22  8:21 [PATCH 0/3] 3 packages for my programs Alex Kost
                   ` (2 preceding siblings ...)
  2016-07-22  8:21 ` [PATCH 3/3] gnu: Add guile-daemon Alex Kost
@ 2016-07-23 11:06 ` Ludovic Courtès
  2016-07-24  6:10   ` Alex Kost
  3 siblings, 1 reply; 11+ messages in thread
From: Ludovic Courtès @ 2016-07-23 11:06 UTC (permalink / raw)
  To: Alex Kost; +Cc: guix-devel

Alex Kost <alezost@gmail.com> skribis:

> Hello, I use these programs all the time, so I think maybe they could be
> useful for someone else.  Is it reasonable to add these packages to
> Guix?

I think so!

Ludo’.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 1/3] gnu: Add xdpyprobe.
  2016-07-22  8:21 ` [PATCH 1/3] gnu: Add xdpyprobe Alex Kost
@ 2016-07-23 11:06   ` Ludovic Courtès
  0 siblings, 0 replies; 11+ messages in thread
From: Ludovic Courtès @ 2016-07-23 11:06 UTC (permalink / raw)
  To: Alex Kost; +Cc: guix-devel

Alex Kost <alezost@gmail.com> skribis:

> * gnu/packages/xdisorg.scm (xdpyprobe): New variable.

OK!

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 2/3] gnu: Add guile-xosd.
  2016-07-22  8:21 ` [PATCH 2/3] gnu: Add guile-xosd Alex Kost
@ 2016-07-23 11:06   ` Ludovic Courtès
  0 siblings, 0 replies; 11+ messages in thread
From: Ludovic Courtès @ 2016-07-23 11:06 UTC (permalink / raw)
  To: Alex Kost; +Cc: guix-devel

Alex Kost <alezost@gmail.com> skribis:

> * gnu/packages/guile.scm (guile-xosd): New variable.

OK!

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/3] gnu: Add guile-daemon.
  2016-07-22  8:21 ` [PATCH 3/3] gnu: Add guile-daemon Alex Kost
@ 2016-07-23 11:07   ` Ludovic Courtès
  2016-07-24  6:13     ` Alex Kost
  0 siblings, 1 reply; 11+ messages in thread
From: Ludovic Courtès @ 2016-07-23 11:07 UTC (permalink / raw)
  To: Alex Kost; +Cc: guix-devel

Alex Kost <alezost@gmail.com> skribis:

> * gnu/packages/guile.scm (guile-daemon): New variable.

OK!

> +    (home-page "https://github.com/alezost/guile-daemon")
> +    (synopsis "Evaluate code in a running Guile process")
> +    (description
> +     "Guile-Daemon is a small Guile program that loads your initial
> +configuration file, and then reads and evaluates Guile expressions that
> +you send to a FIFO file.")

This looks a lot like ‘guile --listen’, except without the REPL prompt
and stuff, right?

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 0/3] 3 packages for my programs
  2016-07-23 11:06 ` [PATCH 0/3] 3 packages for my programs Ludovic Courtès
@ 2016-07-24  6:10   ` Alex Kost
  0 siblings, 0 replies; 11+ messages in thread
From: Alex Kost @ 2016-07-24  6:10 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: guix-devel

Ludovic Courtès (2016-07-23 14:06 +0300) wrote:

> Alex Kost <alezost@gmail.com> skribis:
>
>> Hello, I use these programs all the time, so I think maybe they could be
>> useful for someone else.  Is it reasonable to add these packages to
>> Guix?
>
> I think so!

Thanks!

-- 
Alex

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/3] gnu: Add guile-daemon.
  2016-07-23 11:07   ` Ludovic Courtès
@ 2016-07-24  6:13     ` Alex Kost
  2016-07-24 22:53       ` Ludovic Courtès
  0 siblings, 1 reply; 11+ messages in thread
From: Alex Kost @ 2016-07-24  6:13 UTC (permalink / raw)
  To: Ludovic Courtès; +Cc: guix-devel

Ludovic Courtès (2016-07-23 14:07 +0300) wrote:

> Alex Kost <alezost@gmail.com> skribis:
>
>> * gnu/packages/guile.scm (guile-daemon): New variable.
>
> OK!
>
>> +    (home-page "https://github.com/alezost/guile-daemon")
>> +    (synopsis "Evaluate code in a running Guile process")
>> +    (description
>> +     "Guile-Daemon is a small Guile program that loads your initial
>> +configuration file, and then reads and evaluates Guile expressions that
>> +you send to a FIFO file.")
>
> This looks a lot like ‘guile --listen’, except without the REPL prompt
> and stuff, right?

Sorry, I don't understand what «without the REPL prompt and stuff» means :-)

I wrote Guile-Daemon because I needed a general-purpose guile process
running all the time to which I can send expressions for evaluating.

So I run 'guile-daemon', and then I can do something like this:

  echo '(something #:useful? #t)' > /path/to/daemon-fifo-file

Actually there is 'gdpipe' shell script that does this redirection:

  gdpipe '(something #:useful? #t)'

As for 'guile --listen', yes, Guile-Daemon also starts a socket to which
you can connect with "M-x geiser-connect-local" or alike.

If anyone is interested, I use it as an OSD daemon, particularly to set
sound volume/muteness and to display it using Guile-XOSD.  Here is a
small demo:

https://raw.github.com/alezost/guile-daemon-config/master/sound-volume-demo.gif

My Guile-Daemon config:
<https://github.com/alezost/guile-daemon-config>.

-- 
Alex

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: [PATCH 3/3] gnu: Add guile-daemon.
  2016-07-24  6:13     ` Alex Kost
@ 2016-07-24 22:53       ` Ludovic Courtès
  0 siblings, 0 replies; 11+ messages in thread
From: Ludovic Courtès @ 2016-07-24 22:53 UTC (permalink / raw)
  To: Alex Kost; +Cc: guix-devel

Alex Kost <alezost@gmail.com> skribis:

> Ludovic Courtès (2016-07-23 14:07 +0300) wrote:
>
>> Alex Kost <alezost@gmail.com> skribis:
>>
>>> * gnu/packages/guile.scm (guile-daemon): New variable.
>>
>> OK!
>>
>>> +    (home-page "https://github.com/alezost/guile-daemon")
>>> +    (synopsis "Evaluate code in a running Guile process")
>>> +    (description
>>> +     "Guile-Daemon is a small Guile program that loads your initial
>>> +configuration file, and then reads and evaluates Guile expressions that
>>> +you send to a FIFO file.")
>>
>> This looks a lot like ‘guile --listen’, except without the REPL prompt
>> and stuff, right?
>
> Sorry, I don't understand what «without the REPL prompt and stuff» means :-)

‘guile --listen’ gives you a REPL prompt, which is nice for interactive
stuff, but less nice for scripting.

> I wrote Guile-Daemon because I needed a general-purpose guile process
> running all the time to which I can send expressions for evaluating.
>
> So I run 'guile-daemon', and then I can do something like this:
>
>   echo '(something #:useful? #t)' > /path/to/daemon-fifo-file
>
> Actually there is 'gdpipe' shell script that does this redirection:
>
>   gdpipe '(something #:useful? #t)'
>
> As for 'guile --listen', yes, Guile-Daemon also starts a socket to which
> you can connect with "M-x geiser-connect-local" or alike.

Understood, it does sound useful.

> If anyone is interested, I use it as an OSD daemon, particularly to set
> sound volume/muteness and to display it using Guile-XOSD.  Here is a
> small demo:
>
> https://raw.github.com/alezost/guile-daemon-config/master/sound-volume-demo.gif

Pretty neat!

Thanks,
Ludo’.

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2016-07-24 22:53 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-07-22  8:21 [PATCH 0/3] 3 packages for my programs Alex Kost
2016-07-22  8:21 ` [PATCH 1/3] gnu: Add xdpyprobe Alex Kost
2016-07-23 11:06   ` Ludovic Courtès
2016-07-22  8:21 ` [PATCH 2/3] gnu: Add guile-xosd Alex Kost
2016-07-23 11:06   ` Ludovic Courtès
2016-07-22  8:21 ` [PATCH 3/3] gnu: Add guile-daemon Alex Kost
2016-07-23 11:07   ` Ludovic Courtès
2016-07-24  6:13     ` Alex Kost
2016-07-24 22:53       ` Ludovic Courtès
2016-07-23 11:06 ` [PATCH 0/3] 3 packages for my programs Ludovic Courtès
2016-07-24  6:10   ` Alex Kost

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).