My configuration for Guile-Daemon

Alex Kost 0f06d1b767 lirc/keys: Add keys to control EMMS mpv speed 7 tahun lalu
modules 0f06d1b767 lirc/keys: Add keys to control EMMS mpv speed 7 tahun lalu
scripts 53273e45f9 Add facility to hide all OSDs 8 tahun lalu
.gitignore 1f77c567b3 Initial commit 8 tahun lalu
COPYING 1f77c567b3 Initial commit 8 tahun lalu
Makefile acc51f388f Add Makefile 7 tahun lalu
README.org b81ae9e642 Add client for LIRC daemon 8 tahun lalu
init.scm be6d5ecdbc init: Use 'current-filename' to define self name 8 tahun lalu
sound-volume-demo.gif b687ef9106 Add "sound-volume-demo.gif" 8 tahun lalu

README.org

About

This is my configuration for Guile-Daemon. I use it for 2 purposes:

  • As the OSD daemon, i.e. to display something (clock, sound volume,
  • etc.) on screen using [[https://github.com/alezost/guile-xosd][Guile-XOSD]].
  • As a client for lircd (instead of irexec), i.e. to handle key
  • signals from my remote control.

sound-volume-demo.gif

Note: along with (xosd) module from Guile-XOSD, my guile modules are used in this config (they have (al ...) form).

Files

  • init.scm is the "config" file itself (it is symlinked to
  • [[file:$XDG_CONFIG_HOME/guile-daemon/init.scm]]). All this file does is: it adds [[file:modules]] directory (see below) to the Guile =%load-path=, and loads =(daemon-config)= module.
  • modules directory contains several modules with the code I use
  • for Guile-Daemon. I split the code into several modules to make "logical pieces", but more importantly to speed-up the start of Guile-Daemon, as these modules are loaded *on demand*: only =(daemon-config)= is loaded on start-up, and it's just a wrapper that autoloads procedures placed in the other modules.

So, for example, (daemon-config osd sound) module is loaded only when osd-sound procedure is called, i.e., when I press one of my sound keys (bound to osd-sound ... — see below) first time.

  • scripts directory contains a couple of shell scripts that send
  • expressions to the Guile Daemon using =gdpipe= (it is a part of Guile-Daemon). This directory is placed in my $PATH so I can use such commands as =osd-text hello= or =osd-sound sset Master 3%+=. For example, I bind several keys to such =osd-sound= commands in my [[https://github.com/alezost/stumpwm-config][stumpwm config]]. The result may be seen in the gif demo above.