[wmii] I wrote a jump-or-exec

From: S.P.Tseng <mendouer_AT_163.com>
Date: Thu, 1 Nov 2007 15:34:55 +0800

Maybe someone like it.

#----------------------------------------
#
fn jump-or-exec {
     switch(`{read_tags | grep $1}) {
     case $1
     wmiir xwrite /ctl view $1
     case *
     if (test -n $2) {
     run_command $2 &
     }; if not {
     run_command $* &
     }
     }
}

You can call it like is

fn Key-$MODKEY-w { jump-or-exec web iceweasel }

--
Received on Thu Nov 01 2007 - 08:35:08 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 16:30:38 UTC