antiright-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Antiright-devel] antiright/ACE-desktop ACE


From: Jeffrey Bedard
Subject: [Antiright-devel] antiright/ACE-desktop ACE
Date: Sun, 22 Jul 2007 07:10:57 +0000

CVSROOT:        /sources/antiright
Module name:    antiright
Changes by:     Jeffrey Bedard <jefbed> 07/07/22 07:10:57

Modified files:
        ACE-desktop    : ACE 

Log message:
        Added Hack() function for running parts of the hack collection.  

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/antiright/ACE-desktop/ACE?cvsroot=antiright&r1=1.43&r2=1.44

Patches:
Index: ACE
===================================================================
RCS file: /sources/antiright/antiright/ACE-desktop/ACE,v
retrieving revision 1.43
retrieving revision 1.44
diff -u -b -r1.43 -r1.44
--- ACE 21 Jul 2007 16:16:39 -0000      1.43
+++ ACE 22 Jul 2007 07:10:57 -0000      1.44
@@ -18,25 +18,36 @@
 
 # /bin/sh should have job control enabled.  (-m)
 
-datadir=$PREFIX/share/ACE-desktop
-icon=$datadir/icons
+ACE_Init()
+{
+       datadir=$PREFIX/share/ACE-desktop
+       icon=$datadir/icons
+       rm -f /tmp/ARO.*
+       # Allow DEBUG from environment.  
+       if [ "$DEBUG" = "" ]; then
+               DEBUG=0
+       fi
+}
+
+Hack()
+{
+       local HACK_DIR=$datadir/hacks
+       local COMMAND="$1"
 
-rm -f /tmp/ARO.*
+       shift
+       exec sh -c "$HACK_DIR/$COMMAND.sh $@"
+}
 
-DEBUG=0
-if [ "$DEBUG" = "1" ]; then
-       #set -vx
-       Debug()
-       {
+Debug()
+{
+       if [ "$DEBUG" = "1" ]; then
+               if [ "$COUNTER" = "" ]; then
+                       COUNTER=0
+               fi
                COUNTER=$(($COUNTER+1))
                echo $COUNTER
-       }
-else
-       Debug()
-       {
-               echo -n
-       }
-fi
+       fi
+}
 
 Get_Temp()
 {
@@ -611,6 +622,9 @@
     exit 2
 }
 
+# Main()
+
+ACE_Init
 while getopts :ctp:r:L:V:A:g: OPT; do
     case $OPT in
        c|+c)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]