0

Let's say I have done this

svn import c:\myproj file:///c:/svn/myproj

I then deleted myproj in repo

Then I do again

svn import c:\myproj file:///c:/svn/myproj

It works but gives a revision number 2 whereas I would like it to restart at 1.

Is it possible ?

Thanks.

3 Answers 3

5

No. The first import is still part of your repository. You could revert to it if you wished -this si what revision control does. If you are really on revision number 2 at this point and made a mistake on the first import, I would just delete the entire repository and recreate it.

2
  • What if the repository has other projects ?
    – asksuperuser
    Oct 29, 2009 at 15:13
  • 1
    If the repository has other projects, the second import of myproj wouldn't give a revision number of 2. Each commit/import in a svn repository increments the revision number. This is a design choice of svn you have to live with.
    – mouviciel
    Oct 29, 2009 at 15:56
1

You will need to open a new project repository if you want to make it revision 1 again.

1

I'm curious as to why you'd want to do this in the first place? The revision number has no hidden meaning, it's simply an arbitrary (albeit sequential) number pointing to a specific point in time.

Of course, if you really want to anyway, I'd suggest just manually deleting the entire repository and creating it again.

2
  • Yes it's arbitrary but why not give it a version meaning by controlling it :)
    – asksuperuser
    Oct 29, 2009 at 18:38
  • 2
    @asksuperuser: you're certainly welcome to try, but it isn't designed for that. there are other ways to set meaningful version numbers in SVN. not to be mean, but the phrase that comes to mind is "you're doing it wrong". Oct 29, 2009 at 19:21

You must log in to answer this question.