[hackers] [wmii] Don't delete bar items for which there are tags on startup.

From: Kris Maglione <jg_AT_suckless.org>
Date: Sat Mar 03 18:14:01 2007

changeset: 1989:c37613f80f35
tag: tip
user: Kris Maglione <jg_AT_suckless.org>
date: Sat Mar 03 12:09:36 2007 -0500
summary: Don't delete bar items for which there are tags on startup.

diff -r 419a897e2b46 -r c37613f80f35 rc/rc.wmii
--- a/rc/rc.wmii Sat Mar 03 09:42:06 2007 -0500
+++ b/rc/rc.wmii Sat Mar 03 12:09:36 2007 -0500
@@ -92,7 +92,7 @@ fn Event-ClientMouseDown {
 # Actions
 fn Action {
         action=$1; shift
- if(whatis Action-$action | 9 grep -s '^fn ') {
+ if(whatis Action-$action | grep -s '^fn ') {
                 Action-$action $* &
         };if not {
                 run_command `{config_whatis $action} $* &
@@ -204,7 +204,7 @@ proglist $PATH >$progs_file &
 
 # Tag Bar Setup
 ifs='#
-'{ for(bar in `{wmiir ls /lbar})
+'{ for(bar in `{comm -1 <{wmiir ls /lbar} <{read_tags}})
                 wmiir remove /lbar/$bar
         seltag=`{wmiir read /tag/sel/ctl}
         for(tag in `{read_tags}) {
Received on Sat Mar 03 2007 - 18:14:01 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:56:07 UTC