wmii

git clone git://oldgit.suckless.org/wmii/
Log | Files | Refs | README | LICENSE

commit d93fc75863eb88dc769870b129ec274c8475b14f
parent 2b618491e045f3470fac270960093deda4a49d77
Author: salva <salva@pandora.hopto.org>
Date:   Fri, 10 Mar 2006 23:50:49 +0000

corrected wrong $OLD_PATH, and removed $PIDFILE hack


Diffstat:
extra/p9p/extern | 2+-
extra/p9p/wmiirc | 24+++++++++---------------
2 files changed, 10 insertions(+), 16 deletions(-)

diff --git a/extra/p9p/extern b/extra/p9p/extern @@ -1,7 +1,7 @@ #!/usr/local/plan9/bin/rc # clean the environment and execute the given command -path=$old_path +path=$OLD_PATH old_path=() apid=() cmd=() diff --git a/extra/p9p/wmiirc b/extra/p9p/wmiirc @@ -1,12 +1,7 @@ #!/usr/local/plan9/bin/rc # configure wmii -PIDFILE=/tmp/ns.$USER.$DISPLAY/`{basename $0}^'pid' fn xwrite {a=$1; shift; echo -n $* | wmiir write $a} -if(test -r $PIDFILE) - kill `{cat $PIDFILE} -echo $pid >$PIDFILE - MODKEY=Alt WMII_FONT='fixed' WMII_NORMCOLORS='#222222 #eeeeee #666666' @@ -27,9 +22,9 @@ wmiir write /def/rules <<END END # BAR CONFIGURATION -wmiir create /bar/foo -xwrite /bar/foo/colors $WMII_SELCOLORS -xwrite /bar/expand foo +wmiir create /bar/spare +xwrite /bar/spare/colors $WMII_SELCOLORS +xwrite /bar/expand spare # MENU CONFIGURATION fn items {ls -lpL $* | awk '!/^d/ && $1 ~ /x/ {print $NF}'| sort | uniq} @@ -87,7 +82,7 @@ oldt='' wmiir read /event| while(e=`{read}) { switch($e(1)) { - case NT + case NewTag t=$e(2) wmiir create /bar/$t if(~ $t $olt) @@ -95,23 +90,23 @@ while(e=`{read}) { if not xwrite /bar/$"t/colors $WMII_SELCOLORS xwrite /bar/$"t/data $e(2) - case RT + case RemoveTag wmiir remove /bar/$e(2) - case TF + case FocusTag t=$e(2) if (! ~ $#oldt 0) xwrite /bar/$oldt/colors $WMII_SELCOLORS xwrite /bar/$t/data $e(2) xwrite /bar/$t/colors $WMII_NORMCOLORS oldt=$e(2) - case LB + case LabelClick xwrite /ctl select $e(2) - case K + case Key switch($e(2)) { case $MODKEY-Control-c xwrite /ws/sel/sel/ctl kill case $MODKEY-Control-w,y - wmiirc& + exec wmiirc case $MODKEY-Control-q,y xwrite /ctl quit case $MODKEY-Control-p @@ -158,4 +153,3 @@ while(e=`{read}) { } } } & -echo $apid >$PIDFILE