Lately I’ve be moving source files around in our source tree. For example placing a bunch of files into a common assembly. I’ve been doing this my deleting the file from CVS and then adding it again in the new spot. The problem is the revision number of the file resets back to 1.1. Is there some simple way to move things without having the number reset.
I probably should have mentioned that I don’t have access to the repository so anything that requires that doesn’t help me but it might help others.
There is no way to move files around with client-only commands. You need access to the servers file system and can move the ‘,v’ file in the repository to a new location. This will keep all history, since CVS records every revision and their comments in that one file.
Keep in mind that files are moved into an ‘Attic’ subfolder (which cannot be seen from the client) when they are deleted. This is how files can be restored after they have been deleted.
Generally there are no immediate problems with this approach, however you have to consider the consequences should you decide to check out an earlier version of your product which might rely on the previous directory structure!
This is where other revision control systems like Subversion have a definitive advantage.