rockstardev
rockstardev

Reputation: 13537

Clear subversion revision info

I want to remove all stored revision info, except for the most up to date version (in an effort to safe space). Is this possible?

Upvotes: 2

Views: 1057

Answers (5)

sbi
sbi

Reputation: 224189

In almost all possible scenarios, HD space is nowadays cheaper than the time you waste now fiddling with this or later trying to find out why/when some function got implemented the way it is without its history. So unless you have a lot of time at hand, but really cannot spent the small amount a 1TB HD costs nowadays, you'd better be off leaving the repository the way it is.

It might be different if you put very large binary files into your repository which frequently change so completely that even the diffs stored per changeset are to big. If that's the case, you might want to consider eliminating just those files from the repository. There are a few questions here on SO dealing with that. Here is an example.

Upvotes: 2

Amos
Amos

Reputation: 1060

Would it not be easier to check out an up to date copy of the project, wipe the repository and use your checked out copy as the basis of a new repository.

Upvotes: 3

Pekka
Pekka

Reputation: 449803

If you can, the arguably easiest way is to export the current version, delete the repository, and set up a new one.

For anything more complex, there is svnadmin dump that can dump specific revisions and revision ranges: Manual

Upvotes: 2

nos
nos

Reputation: 229342

Not directly. What you'd do is:

  • Check out/Export the latest revision.
  • Create a new repository.
  • Import the checked out version into the new repository.
  • Switch the old repository with the new one.

Upvotes: 2

Marcelo Cantos
Marcelo Cantos

Reputation: 186108

Export the latest working copy, then import the result into a brand new repository. You might not save that much space, though, due to the way svn stores revisions.

Upvotes: 3

Related Questions