Enlightenment CVS committal

Author  : mej
Project : eterm
Module  : Eterm

Dir     : eterm/Eterm/utils


Modified Files:
      Tag: ETERM-0_10
        Etbg_update_list 


Log Message:
Tue Dec  9 22:35:24 2003                        Michael Jennings (mej)

  \  |                       
 |\/ |   -_)   _| _` |   -_) 
_|  _| \___| _| \__, | \___| 
                ____/        

===================================================================
RCS file: /cvsroot/enlightenment/eterm/Eterm/utils/Etbg_update_list,v
retrieving revision 1.3.2.1
retrieving revision 1.3.2.2
diff -u -3 -r1.3.2.1 -r1.3.2.2
--- Etbg_update_list    24 Aug 2003 15:16:45 -0000      1.3.2.1
+++ Etbg_update_list    10 Dec 2003 03:38:11 -0000      1.3.2.2
@@ -2,7 +2,7 @@
 #
 # Eterm backgrounds list file update utility
 #
-# $Id: Etbg_update_list,v 1.3.2.1 2003/08/24 15:16:45 mej Exp $
+# $Id: Etbg_update_list,v 1.3.2.2 2003/12/10 03:38:11 mej Exp $
 
 LISTFILE=pixmaps.list
 
@@ -17,18 +17,18 @@
 fi
 
 if [ "x$1" = "x-h" -o "x$1" = "x--help" ]; then
-  echo "Syntax:  Etbg_update_list [path]"
-  echo "   (The default path is the current directory.)"
-  echo
-  exit 0
+    echo "Syntax:  Etbg_update_list [path]"
+    echo "   (The default path is the current directory.)"
+    echo
+    exit 0
 fi
 
 # Find the pixmap directory
 for i in "$1" "$PWD" "$PWD/pix" "$PWD/../pix" ; do
-  if [ -d "$i/tile" -o -d "$i/scale" ]; then
-    PIXDIR="$i"
-    break
-  fi
+    if [ -d "$i/tile" -o -d "$i/scale" ]; then
+        PIXDIR="$i"
+        break
+    fi
 done
 
 cd $PIXDIR
@@ -48,13 +48,13 @@
   title Tiled
 EOF
 if [ -d tile ]; then
-  for i in `(cd tile && ls -1)` ; do 
-    echo '"tile/'$i'@0x0+0+0:tile"' >> $LISTFILE.new
-    echo "  begin menuitem" >&3
-    eval echo "\ \ \ \ text \\\"\`echo $i | $SEDCMD\`\\\"" >&3
-    echo "    action string \"\\e]20;tile/$i;0x0+0+0:tile\\a\"" >&3
-    echo "  end" >&3
-  done
+    for i in `(cd tile && ls -1)` ; do 
+        echo '"tile/'$i'@0x0+0+0:tile"' >> $LISTFILE.new
+        echo "  begin menuitem" >&3
+        eval echo "\ \ \ \ text \\\"\`echo $i | $SEDCMD\`\\\"" >&3
+        echo "    action string \"\\e]20;tile/$i;0x0+0+0:tile\\a\"" >&3
+        echo "  end" >&3
+    done
 fi
 cat >&3 <<EOF
 end
@@ -63,40 +63,41 @@
 EOF
 
 if [ -d scale ]; then
-  for i in `(cd scale && ls -1)` ; do \
-    echo '"scale/'$i'@100x100"' >> $LISTFILE.new ; \
-    echo "  begin menuitem" >&3
-    eval echo "\ \ \ \ text \\\"\`echo $i | $SEDCMD\`\\\"" >&3
-    echo "    action string \"\\e]20;tile/$i;0x0+0+0:tile\\a\"" >&3
-    echo "  end" >&3
-  done
+    for i in `(cd scale && ls -1)` ; do \
+        echo '"scale/'$i'@100x100"' >> $LISTFILE.new ; \
+        echo "  begin menuitem" >&3
+        eval echo "\ \ \ \ text \\\"\`echo $i | $SEDCMD\`\\\"" >&3
+        echo "    action string \"\\e]20;tile/$i;0x0+0+0:tile\\a\"" >&3
+        echo "  end" >&3
+    done
 fi
 echo "end" >&3
 
 # Check to see if the list has changed.  If so, back up the old one.
 if [ -s $LISTFILE ]; then
-  if (diff $LISTFILE $LISTFILE.new >/dev/null 2>&1); then
-    echo "Pixmap list is unchanged."
-    rm -f $LISTFILE.new
-  else
-    echo "Old pixmap list will be saved in $LISTFILE.old"
-    mv -f $LISTFILE $LISTFILE.old
-  fi
+    if (diff $LISTFILE $LISTFILE.new >/dev/null 2>&1); then
+        echo "Pixmap list is unchanged."
+        rm -f $LISTFILE.new
+    else
+        echo "Old pixmap list will be saved in $LISTFILE.old"
+        mv -f $LISTFILE $LISTFILE.old
+    fi
 fi
 if [ -s $LISTFILE.new ]; then
-  mv -f $LISTFILE.new $LISTFILE
+    mv -f $LISTFILE.new $LISTFILE
 fi
 
 # If there's no theme directory nearby, just quit.
 if [ ! -d "../themes" ]; then
-  exit 0
+    exit 0
 fi
 
 # If there is, cd into it and make sure all the themes have list files.
 cd ../themes
 for i in `ls -1` ; do
-  if [ -f $i/theme.cfg -a ! -e $i/$LISTFILE ]; then
-    echo "Creating symlink to $LISTFILE for theme $i"
-    (cd $i && ln -f -s ../../pix/$LISTFILE $LISTFILE)
-  fi
+    if [ -f $i/theme.cfg -a ! -f $i/$LISTFILE ]; then
+        echo "Creating symlink to $LISTFILE for theme $i"
+        rm -f $i/$LISTFILE
+        ln -f -s ../../pix/$LISTFILE $i/$LISTFILE
+    fi
 done




-------------------------------------------------------
This SF.net email is sponsored by: IBM Linux Tutorials.
Become an expert in LINUX or just sharpen your skills.  Sign up for IBM's
Free Linux Tutorials.  Learn everything from the bash shell to sys admin.
Click now! http://ads.osdn.com/?ad_id=1278&alloc_id=3371&op=click
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs

Reply via email to