[hackers] [wmii] Have rc.wmii source rc.wmii.local to allow local changes with the stock rc.wmii.

From: Kris Maglione <jg_AT_suckless.org>
Date: Sat Feb 24 01:54:34 2007

changeset: 1947:238385a88e5d
tag: tip
user: Kris Maglione <jg_AT_suckless.org>
date: Fri Feb 23 19:50:02 2007 -0500
summary: Have rc.wmii source rc.wmii.local to allow local changes with the stock rc.wmii.

diff -r 24bad3d1a0d6 -r 238385a88e5d rc/rc.wmii
--- a/rc/rc.wmii Fri Feb 23 16:53:38 2007 -0500
+++ b/rc/rc.wmii Fri Feb 23 19:50:02 2007 -0500
@@ -178,6 +178,39 @@ for(i in `{seq 0 9}) {
         }
 }
 
+# Functions
+fn proglist {
+ /bin/ls -lL `{echo $* | tr : ' '} >[2]/dev/null |
+ awk '$1 ~ /^[^d].*x/ { print $NF }' |
+ sort | uniq
+}
+
+fn actionlist {
+ { proglist $WMII_CONFPATH;
+ env | sed -n 's/^fn#Action-([^=]+).*/\1/p'
+ } | sort | uniq
+}
+
+fn read_tags {
+ wmiir ls /tag | sed 's,/,,; /^sel$/d'
+}
+
+fn config_whatis {
+ confpath=`{echo $WMII_CONFPATH | sed 'y/:/ /'}
+ prog=$1; shift
+ echo `{{path=$confpath whatis $prog} | grep -v '=|^fn '} $*
+}
+
+fn run_command {
+ rfork ens
+ path=$oldpath \
+ eval exec $* </dev/null
+}
+
+local = `{config_whatis rc.wmii.local}
+if(! ~ $#local 0)
+ . $local
+
 # WM Configuration
 wmiir write /ctl <<!
 grabmod $MODKEY
@@ -186,35 +219,6 @@ focuscolors $WMII_FOCUSCOLORS
 focuscolors $WMII_FOCUSCOLORS
 normcolors $WMII_NORMCOLORS
 !
-
-# Functions
-fn proglist {
- /bin/ls -lL `{echo $* | tr : ' '} >[2]/dev/null |
- awk '$1 ~ /^[^d].*x/ { print $NF }' |
- sort | uniq
-}
-
-fn actionlist {
- { proglist $WMII_CONFPATH;
- env | sed -n 's/^fn#Action-([^=]+).*/\1/p'
- } | sort | uniq
-}
-
-fn read_tags {
- wmiir ls /tag | sed 's,/,,; /^sel$/d'
-}
-
-fn config_whatis {
- confpath=`{echo $WMII_CONFPATH | sed 'y/:/ /'}
- prog=$1; shift
- echo `{{path=$confpath whatis $prog} | grep -v '=|^fn '} $*
-}
-
-fn run_command {
- rfork ens
- path=$oldpath \
- eval exec $* </dev/null
-}
 
 # Misc Setup
 xsetroot -solid $WMII_BACKGROUND
Received on Sat Feb 24 2007 - 01:54:34 UTC

This archive was generated by hypermail 2.2.0 : Sun Jul 13 2008 - 15:55:51 UTC