You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Sander Roobol <ph...@wanadoo.nl> on 2003/03/06 12:41:37 UTC

Re: [PATCH] normalize path of repository in hot-backup.py

On Fri, Feb 07, 2003 at 02:06:51PM +0200, Jani Averbach wrote:
> 
> Hello!
> 
> Basename will return '' if you call it with '/foo/bar/', as opposed to
> the UNIX basename (result will be '/foo/bar') [1]. So the 'repo_dir' in
> hot-backup.py have to be normalized and absolutized before call of
> basename. With this patch hot-backup.py will work correctly in this case:
> "./hot-backup.py /repo_path/repo/  /backup_dir".
> 
> BR, Jani
> 
> 1) http://www.python.org/doc/current/lib/module-os.path.html

Still looks like a valid problem to me. Can someone take a look at it?

Sander

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

Re: [PATCH] normalize path of repository in hot-backup.py

Posted by Michael Price <mp...@atl.lmco.com>.
Jani Averbach writes:
 > On Thu, 6 Mar 2003, Sander Roobol wrote:
 > 
 > > Still looks like a valid problem to me. Can someone take a look at it?
 > 
 > I think that this is still valid fix.

+1

Michael


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

weekly patch digest [Was: Re: [PATCH] normalize path of repository in hot-backup.py]

Posted by Sander Roobol <ph...@wanadoo.nl>.
On Thu, Mar 06, 2003 at 10:50:08PM +0100, Branko ??ibej wrote:
> Sander, are you open to a small suggestion? Instead of asking separately
> about every outstanding patch, you could maybe make a list of subjects
> and links to the threads in the list archives (and possibly issue
> numbers for those patches that have them), together with comments on
> status (open, closed, don't-know, etc.).
> 
> Then post the whole list from time to time, say once a week.
> 
> In the meantime, at least the people who posted patches are sure to give
> you feedback about what's still valid, what's waiting for approval, what
> has already been approved and is waiting for commit, etc. I think that
> everybody would have a better idea about how big the patch stack is, and
> we can start thinking about priorities.

I think that's a great idea. I currently have 19 patches flagged,
I'll post a list shortly.

Sander

> 
> I think you're doing a great job, by the way, and a very necessary one.
> Thanks!
> 
>     Brane

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

Re: [PATCH] normalize path of repository in hot-backup.py

Posted by Jani Averbach <ja...@cc.jyu.fi>.
On Thu, 6 Mar 2003, Sander Roobol wrote:

> Still looks like a valid problem to me. Can someone take a look at it?
>

I think that this is still valid fix.

BR, Jani

P.S. This new patch-manager system looks like promising. Thanks for
picking this up from floor.

Log:

The repo_dir have to be normalized and absolutized before call of
basename. Otherwise "./hot-backup.py /repo_path/repo/ /backup_dir" won't
work, the result will be /backup_dir/-<repo_num> instead of
/backup_dir/<repo>-<repo_num>.


* tools/backup/hot-backup.py.in:
  Added os.path.abspath() call before call of os.path.basename


Index: hot-backup.py.in
===================================================================
--- hot-backup.py.in    (revision 5216)
+++ hot-backup.py.in    (working copy)
@@ -49,7 +49,7 @@

 # Path to repository
 repo_dir = sys.argv[1]
-repo = os.path.basename(repo_dir)
+repo = os.path.basename(os.path.abspath(repo_dir))

 # Where to store the repository backup.  The backup will be placed in
 # a *subdirectory* of this location, named after the youngest


--
Jani Averbach



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