Update of /cvsroot/hcoop/misc/scripts
In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv30102

Modified Files:
        apache-sync-logs 
Log Message:

* In verbose mode, improve error/status reporting by printing
  the actual reason whenever someone's directory is skipped and
  not synced

* Commit changes someone did directly in scripts/ and didn't 
  commit to cvs



Index: apache-sync-logs
===================================================================
RCS file: /cvsroot/hcoop/misc/scripts/apache-sync-logs,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** apache-sync-logs    18 Dec 2007 21:32:11 -0000      1.14
--- apache-sync-logs    4 Feb 2009 18:09:33 -0000       1.15
***************
*** 32,35 ****
--- 32,38 ----
      # Skip deleted or empty log directories
      if test ! -d "$LOG_SRC" || ! ls "$LOG_SRC"/*/*/*.log >/dev/null 2>&1; then
+         if test "$VERBOSE" = "true"; then
+               echo "Skipping $USER (deleted or empty log dir $LOG_SRC)"
+         fi
          continue
      fi
***************
*** 38,41 ****
--- 41,47 ----
      if test -d "$USER_HOME/.logs" && \
          ! ls "$USER_HOME/.logs" >/dev/null 2>&1; then
+         if test "$VERBOSE" = "true"; then
+               echo "Skipping $USER (unreadable log dir $USER_HOME/.logs)"
+         fi
          continue
      fi
***************
*** 43,46 ****
--- 49,55 ----
      # Skip people who do not have keytabs
      if test ! -f "$KEYTAB_DIR/$USER"; then
+         if test "$VERBOSE" = "true"; then
+               echo "Skipping $USER (missing keytab $KEYTAB_DIR/$USER)"
+         fi
          continue
      fi
***************
*** 54,59 ****
  
      if test ! -d "$LOG_DEST"; then
!         echo "Error: $LOG_DEST does not exist, please make it"
!         ERROR=yes
      else
          rm -fr $TMP_DEST
--- 63,74 ----
  
      if test ! -d "$LOG_DEST"; then
! #        echo "Error: $LOG_DEST does not exist, please make it"
! #        ERROR=yes
! # We will assume that people know what they are doing when they
! # delete their ~/.logs/apache directory ....
!         if test "$VERBOSE" = "true"; then
!               echo "Skipping $USER (no $LOG_DEST directory)"
!         fi
!         continue
      else
          rm -fr $TMP_DEST
***************
*** 62,66 ****
          chmod -R u=rwX,go=X $TMP_DEST
          k5start -qtU -f $KEYTAB_DIR/$USER \
!             -- su $USER -c "rsync -a $TMP_DEST/ $LOG_DEST/"
          rm -fr $TMP_DEST
          test "$VERBOSE" = "true" && echo "  done."
--- 77,81 ----
          chmod -R u=rwX,go=X $TMP_DEST
          k5start -qtU -f $KEYTAB_DIR/$USER \
!             -- sudo -u $USER rsync -a $TMP_DEST/ $LOG_DEST/
          rm -fr $TMP_DEST
          test "$VERBOSE" = "true" && echo "  done."


------------------------------------------------------------------------------
Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM)
software. With Adobe AIR, Ajax developers can use existing skills and code to
build responsive, highly engaging applications that combine the power of local
resources and data with the reach of the web. Download the Adobe AIR SDK and
Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com
_______________________________________________
hcoop-cvs mailing list
hcoop-cvs@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/hcoop-cvs

Reply via email to