You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Michael <mi...@ispwest.com> on 2003/02/25 16:29:05 UTC

Re: svn commit: rev 5090 - trunk/tools/backup

cmpilato@tigris.org writes:
 > Author: cmpilato
 > Date: 2003-02-25 09:58:25 -0600 (Tue, 25 Feb 2003)
 > New Revision: 5090
 > 
 > Modified:
 >    trunk/tools/backup/hot-backup.py.in
 > Log:
 > * subversion/tools/backup/hot-backup.py.in
 >   $-terminate the regexp for filtering out stuff we don't want to
 >   delete.  This was causing nothing to be removed on svn.collab.net
 >   (because there are dirs named 'svn-1234.KEEP' in the directory).
 > 
 > Modified: trunk/tools/backup/hot-backup.py.in
 > ==============================================================================
 > --- trunk/tools/backup/hot-backup.py.in	(original)
 > +++ trunk/tools/backup/hot-backup.py.in	Tue Feb 25 09:58:29 2003
 > @@ -214,7 +214,7 @@
 >  ###         NUM_BACKUPS.
 >  
 >  if num_backups > 0:
 > -  regexp = re.compile("^" + repo + "-[0-9]+")
 > +  regexp = re.compile("^" + repo + "-[0-9]+$")
 >    directory_list = os.listdir(backup_dir)
 >    old_list = filter(lambda x: regexp.search(x), directory_list)
 >    old_list.sort(comparator)

That will now fail to remove incremental directories. If you want to add
the terminator then you have to do something like:

  regexp = re.compile("^" + repo + "-[0-9]+(-[0-9]+)?$")

Michael


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: svn commit: rev 5090 - trunk/tools/backup

Posted by cm...@collab.net.
Michael <mi...@ispwest.com> writes:

> That will now fail to remove incremental directories. If you want to add
> the terminator then you have to do something like:
> 
>   regexp = re.compile("^" + repo + "-[0-9]+(-[0-9]+)?$")

Yep, you're so right.  Will fix.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org