Reputation: 1030
I copied a bunch of java classes into another java package outside of perforce by accident and made a bunch of changes to them. I now realised that the revision history of those files has been lost as I didn't use perforce to copy the files over.
Example:
original file - dir1/Class1.java
copied file - dir2/Class1.java
The original file still exists.
If I want to restore the revision history of the files what would be the appropriate command to run in order to do this?
Upvotes: 1
Views: 298
Reputation: 18135
You should have branched the file in Perforce rather than copied it outside of Perforce, but that can be remedied.
dir2/Class1.java
to another location then delete the originaldir1/Class1.java
to dir2/Class1.java
dir2/Class1.java
dir2/Class1.java
dir2/Class1.java
You will then have your recent modifications to the file dir2/Class1.java
in version control and the file will be linked to its original via the branch history.
Upvotes: 2