So I have a Subversion Repo /project which was last updated 2 months ago. Some changes where made on the production site (Yeah not my idea, one of the other dev's) and now I need to add those changes into the subversion repo.
So I've zipped up the production files/directories and c开发者_如何学JAVAopied them onto my local dev box, also checkout the latest copy of the repo on my dev box as well. There are a number of new files/directories as well as some changes in some of the current files.
What would be the best approach to adding these changes into subversion? Is it as easy as copying the new files from the zip into the local repo project and committing that way? (I did this and I don't see all of the changes).
Any thoughts?
NOTE: I'm using the command line svn no GUI
EDIT:
Yeah no large structural changes, just added some libraries (directories) and added some need functionality into the existing scripts
Here's what I would do:
- Create a new branch of the project
- Get a checkout of the branch on your dev box
- Add the files from production to the branch checkout.
- add/commit the production files
- merge the branch into the repository
- curse at the dev that updated production while you fix all the conflicts.
Copy the new files and folders into your project. Add them using your favourite subversion client.
Use a merge tool to compare all production files with your working copy. winmerge is a great tool for this and then merge over the parts you want.
Commit your changes.
The best way would be to update your working copy to the revision that exists on the production server, then move the existing files from the production server into that working copy, if you now update the working copy (with changed files) subversion will merge changes after that revision to HEAD.
This will probably give you some conflicts though, depending on how much has changed.
I would right-click on your folder and the SVN menu will give you an option to check for modifications. You can see what has been changed and just revert to what is in the repository or merge changes you may have made.
精彩评论