[jboss-cvs] JBossAS SVN: r86727 - in projects/ejb3/trunk/hudson: svn and 1 other directory.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Fri Apr 3 03:16:04 EDT 2009


Author: wolfc
Date: 2009-04-03 03:16:04 -0400 (Fri, 03 Apr 2009)
New Revision: 86727

Added:
   projects/ejb3/trunk/hudson/svn/
   projects/ejb3/trunk/hudson/svn/fix_rev.sh
Log:
workaround for http://subversion.tigris.org/issues/show_bug.cgi?id=3194


Added: projects/ejb3/trunk/hudson/svn/fix_rev.sh
===================================================================
--- projects/ejb3/trunk/hudson/svn/fix_rev.sh	                        (rev 0)
+++ projects/ejb3/trunk/hudson/svn/fix_rev.sh	2009-04-03 07:16:04 UTC (rev 86727)
@@ -0,0 +1,35 @@
+#!/bin/sh
+# vim:ts=3:sw=3:expandtab:
+set -e
+#set -x
+
+# Fix the svn:date of a revision in a SVN mirror
+# http://subversion.tigris.org/issues/show_bug.cgi?id=3194
+
+if [ $# != 2 ]; then
+   echo 1>&2 "Usage: $0 <repos> <rev>"
+   exit 1
+fi
+
+REPOS="$1"
+REV="$2"
+
+DATE=`svn pg -r $REV --revprop svn:date $REPOS`
+
+if [ -n "$DATE" ]; then
+   echo "$REV already has a date"
+   exit 0
+fi
+
+PREV_REV=$REV
+while [ -z "$DATE" ]; do
+   PREV_REV=`expr $PREV_REV - 1`
+   if [ $PREV_REV == -1 ]; then
+      echo 1>&2 "can't find a previous date for $REV"
+      exit 1
+   fi
+   DATE=`svn pg -r $PREV_REV --revprop svn:date $REPOS`
+done
+echo $DATE
+
+svn ps -r $REV --revprop svn:date $DATE $REPOS


Property changes on: projects/ejb3/trunk/hudson/svn/fix_rev.sh
___________________________________________________________________
Name: svn:executable
   + *
Name: svn:eol-style
   + native




More information about the jboss-cvs-commits mailing list