scripts

various script and utils
git clone git://z3bra.org/scripts
Log | Files | Refs

commit c41b8d074d9ea92ebb67f55f0d93485a7b28e7aa
parent 53a88e98d9ff8a8b120f305c97bcceac0ae45593
Author: z3bra <willy@mailoo.org>
Date:   Tue May  6 15:28:14 +0200

Notification daemon. Creates a pipe to get notifications

Diffstat:
wrappop | 25+++++++++++++++++++++++++
1 file changed, 25 insertions(+), 0 deletions(-)
diff --git a/wrappop b/wrappop @@ -0,0 +1,25 @@ +#!/bin/sh + +# fifo that we'll use to feed the popups +test -p /tmp/popup.fifo || mkfifo /tmp/popup.fifo + +w=150 +h=20 +x=1930 +y=10 + +n=-1 + +# get messages from the fifo +tail -f /tmp/popup.fifo | +while IFS= read -r message; do + # increment the counter + n=$((n + 1)) + + # display the popup under the others + { + ~/bin/popup -g ${w}x${h}+${x}+$((y + (h+y) * n)) $n ${message} + # decrement the counter + n=$((n - 1)) + } & +done