[csw-devel] SF.net SVN: gar:[12078] csw/mgar/pkg/exim/branches/dir-loc-fixes/files/ CSWexim.preinstall

bdwalton at users.sourceforge.net bdwalton at users.sourceforge.net
Fri Dec 24 02:24:46 CET 2010


Revision: 12078
          http://gar.svn.sourceforge.net/gar/?rev=12078&view=rev
Author:   bdwalton
Date:     2010-12-24 01:24:46 +0000 (Fri, 24 Dec 2010)

Log Message:
-----------
exim/branches/dir-loc-fixes: update the log and spool preinstall migration logic

Modified Paths:
--------------
    csw/mgar/pkg/exim/branches/dir-loc-fixes/files/CSWexim.preinstall

Modified: csw/mgar/pkg/exim/branches/dir-loc-fixes/files/CSWexim.preinstall
===================================================================
--- csw/mgar/pkg/exim/branches/dir-loc-fixes/files/CSWexim.preinstall	2010-12-23 23:15:06 UTC (rev 12077)
+++ csw/mgar/pkg/exim/branches/dir-loc-fixes/files/CSWexim.preinstall	2010-12-24 01:24:46 UTC (rev 12078)
@@ -1,22 +1,24 @@
 #!/bin/sh
 
 PIR=${PKG_INSTALL_ROOT:-}
-SPOOLOLD=${PIR}/opt/csw/var/spool
-SPOOLNEW=${PIR}/var/opt/csw/spool
-LOGOLD=${PIR}/opt/csw/var/log
-LOGNEW=${PIR}/var/opt/csw/log
+SPOOLOLD=${PIR}/opt/csw/var/spool/exim
+SPOOLNEW=${PIR}/var/opt/csw/spool/exim
+LOGOLD=${PIR}/opt/csw/var/log/exim
+LOGNEW=${PIR}/var/opt/csw/log/exim
 COPY="cp -pR"
 
-if [ -d "${SPOOLOLD}/exim" -a ! -d "${SPOOLNEW}/exim" ]; then
+if [ -d "${SPOOLOLD}/" -a ! -d "${SPOOLNEW}/db" ]; then
     echo "Transferring existing spool files to new location..."
-    $COPY "${SPOOLOLD}/exim" "${SPOOLNEW}/"
+    $COPY "${SPOOLOLD}/*" "${SPOOLNEW}/"
 else
-    echo "New spool directory exists already.  Not touching anything."
+    echo "Looks like the new spool directory is in use already."
+    echo "Not touching anything."
 fi
 
-if [ -d "${LOGOLD}/exim" -a ! -d "${LOGNEW}/exim" ]; then
+if [ -d "${LOGOLD}" -a ! -f "${LOGNEW}/mainlog" ]; then
     echo "Transferring existing log files to new location..."
-    $COPY "${LOGOLD}/exim" "${LOGNEW}/"
+    $COPY "${LOGOLD}/*" "${LOGNEW}/"
 else
-    echo "New log directory exists already.  Not touching anything."
+    echo "Looks like the new log directory is in use already."
+    echo "Not touching anything."
 fi


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.


More information about the devel mailing list