displaying the result of a shell command as window title strings



Hi sawfishers!

I'm using the mxflat theme from
http://themes.freshmeat.net/projects/mxflat/ and it allows me to
customize the windows' title strings. For example one can evaluate
lisp expressions like this $[current-time-string] and the result of
the evaluation will appear as window titles. One can also take the
value of environment variables like this $(DISPLAY).

This is all great but now I would like to have the output of a shell
script displayed as title string. It's actually the battery status of
my laptop. From the .sawfishrc file I know that ( system
"/path/to/program" ) is valid but $[system "/path/to/program"] doesn't
work for the title strings.

Does anyone know how (and where) to define a lisp expression that
would return the output of a shell script? I'm looking for something
like current-time-string which apparently works.

Cheers,
Daniel


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]