[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[PATCH] Make target repo path changeable in cvs2svn (Was Re: [PATCH]: Revised cvs2svn.py patches)

From: Daniel Berlin <dan_at_dberlin.org>
Date: 2002-02-12 07:08:28 CET

Sigh, of course, i send the old version of the patch that doesn't work
right because python only evaluates the default arguments once, at
function definition time.

> >
> > >
> > > > + opts, args = getopt.getopt(sys.argv[1:], 'p:h:v')
> > >
> > > Not doing this (yet?).
> > Errr, you could have just changed it to set the SVNROOT variable instead.
> > It's intended to be the home of the new repository.
> >
> > Right now, you always create it named "svnroot", which is a real pain for
> > testing conversions.
> >
> > --Dan

I meant to send:
Index: ./cvs2svn.py
===================================================================
--- ./cvs2svn.py
+++ ./cvs2svn.py Tue Feb 12 01:04:54 2002
@@ -617,11 +617,11 @@
     print ' total:', int(times[len(_passes)] - times[start_pass-1]), 'seconds'
 
 def usage():
- print 'USAGE: %s [-v] [-p pass] repository-path' % sys.argv[0]
+ print 'USAGE: %s [-v] [-h svn-repository-path] [-p pass] repository-path' % sys.argv[0]
   sys.exit(1)
 
 def main():
- opts, args = getopt.getopt(sys.argv[1:], 'p:v')
+ opts, args = getopt.getopt(sys.argv[1:], 'p:h:v')
   if len(args) != 1:
     usage()
 
@@ -637,8 +637,10 @@
         sys.exit(1)
     elif opt == '-v':
       verbose = 1
+ elif opt == '-h':
+ target_repo = value
 
- util.run_app(convert, args[0], start_pass=start_pass, verbose=verbose)
+ util.run_app(convert, args[0], start_pass=start_pass, verbose=verbose, target=target_repo)
 
 if __name__ == '__main__':
   main()

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Oct 21 14:37:06 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.