Svn Walkthrough
Here is how to get started using SVN in the TWO project:
Contents
Access
- First you must be invited to contribute to the TWO movie project. See Getting Started.
- Then you must have followed the Dot Project instructions, and have the correct Dot Project access level.
- Then you must email willp@hash.com and give him your forum username and a Svn Password you want to use for svn.
Install
- If you don’t have SVN or a supported svn client installed, install one from the Svn Install page.
- Download and install the latest A:M v13.0
First Update
- Turn on the Community panel under the View menu.
- Undock the Community panel by double clicking its title. This is because there is a refresh issue in the Alpha version. Size the panel how you wish.
- On the Community panel, log in if you are not already, and switch to the TWO Movie tab
Even if you have registered with the forum you will need to be registered here. You can use the same name and password as the forum if you wish though. - Press the ’Update’ button. It will bring up a dialog asking for what folder you want the TWO data in.
- Then it will ask you “Would you like to select only a portion of the Repository to work on?”
- If you pick “Yes”, It will tell you to pick the “Repository URL” button from the tools, options dialog that it brings up.
- Press the “Repository URL” button.
Enable Svn should have been checked for this screen shot - Expand and uncheck the first folder, and expand its sub folders to find and check “dataShared Data”, “dataLibraries”, and the scene(s) from dataActnumbersequencenumberscenenumber that you will be working on.
- When you have the parts you need checked, press ok, on the repository browser, and the options panel.
- Then it will bring up a dialog asking you for your forum sign in name and password. Instead email willp@hash.com and give him your forum user name and a Svn Password you want to use for svn. (We haven’t had time to tie it to the forum login yet)
- Then it will bring up a dialog asking you where to ”check out” from. Press ok to download the data to the folder you specified. (Don’t change any info here unless you know what you are doing).
- If you choose to get only part of the repository you will need to press “Update” until you you are done checking out the folders you choose.
- Add "TWODATAFOLDERDataLibraries" to the “Tools”, “Options”, “Folders”, “Libraries (lbr files)”, “Folders:” list. (WARNING until this note is removed don’t add to the TWO.lbr file except with a text editor).
Daily Use
Remember to follow the filename and folder layout guidelines on the Data Management page.
- You can now open from or save files to the folders you checked out in the folder you choose to put the data in, to add or modify what has been assigned to you on Dot Project.
- To add new files.
- If you are using TortoiseSVN check “Show unversioned files”, check any unversioned files you want to add before pressing ok.
Don’t add .hinfo files, or thumbs.db files. - Or you can right click on a linked file in the PWS and pick “Add”.
- If you are using TortoiseSVN check “Show unversioned files”, check any unversioned files you want to add before pressing ok.
- If you are going to be working on more than one file and want to send one before the other is finished you’ll need to use TortoiseSVN on the pc or SvnX on OSX to “commit” (svn for ‘send’) just the file you are finished with.
- To add new files.
- When you have completed a step press the ’Commit’ button. An “Enter Log Message” dialog will appear. Enter a description of what changes you did, and press “Ok”. A:M will send all modified files in the TWO data folder you checked out above.
- Press ’ Update’ again and it will bring up a dialog listing all the files others have modified since you last updated.
- Remember to update before you start work on a new task
- Remember to save and then commit your changes often. That way you can get a previous commit of a file if you lose your work or don’t like a change you saved.
Commit
Here is what can happen when you commit your changes.
- If nobody else changed the files you changed it will commit them without a hitch.
- Or if someone changed a file you changed it will notify you with an error like this.
Modified: somefile.ext Error: Commit failed (details follow): Error: Your file or directory 'Action.cpp' is probably out-of-date Error: The version resource does not correspond to the resource within the transaction. Either the requested version resource is out of date (needs to be updated), or the requested version resource is newer than the transaction root (restart the commit).
This means that you need to press ’ Update’ for svn to get the changes and merge them into your changes. Then one of two things can happen.
- A merge because another person has changed a separate part of the file. Svn will automatically merge those changes into yours.
- Then just ’Commit’ to send the merged file.
- Or a conflict because another person has changed the same part of the file you did. You will get an error telling you that you need to resolve a conflict before commiting.
- Resolve the conflict. See Svn Conflict.
- ’Commit’ the resolved files.
- A merge because another person has changed a separate part of the file. Svn will automatically merge those changes into yours.
How to avoid Svn Conflicts
The easiest way to avoid conflicts is to make sure that the last person working on a file has successfully sent the file with the ‘Commit’ button on the TWO community tab. And you have updated that version of the file. As long as no one else commits before you complete your work and commit there will be no conflicts.
- Coordinate files with Dot Project tasks
- Make sure you are assigned to a task for the files you are working on.
- Make sure the last task assignee has sent his work.
- update before editing
- commit right after editing
Two people can collaborate on a file, but you must be willing deal with the possibility of conflicts.
Here is a list of some of the ways you can get conflicts and how to avoid them.
- Two people adding something to the same part of the file will cause a conflict
- Starting with the same empty choreography Thom adds a model and Diane adds a light.
- If Thom and Diane knew that they were going to have this conflict they could have avoided it by having Thom add a new folder to the choreography, and ‘commit’ it. Then Diane could ‘update’ it. Thom could add the model and Diane could add the light inside of the folder.
- Or they could have decided that Thom would add objects to the top of the choreography in the PWS, and Diane would only add objects to the bottom of the PWS
- If Thom and Diane knew that they were going to have this conflict they could have avoided it by having Thom add a new folder to the choreography, and ‘commit’ it. Then Diane could ‘update’ it. Thom could add the model and Diane could add the light inside of the folder.
- Two people can’t make new actions in the same project. The folder trick above will help avoid this.
- Two people shouldn’t add cps to the same .mdl. If you get a conflict in the MESH section and both files have added cps please send the three conflict files: filename.r(lownumber), filename.mine, and filename.r(highnumber); to a Technical Director and let him merge the differences and send the resolved file back to you. cpid conflicts are bad news (—Noel)
- Starting with the same empty choreography Thom adds a model and Diane adds a light.
Here is a list of things that shouldn’t cause conflicts:
- Two people can work in two separate files.
- Two people can work in a totally separate section of the same file.
- Two people moving control points as long as they don’t move the same ones
- Two people adding keys to a channel as long as they add them on either side of an existing keyframe.
- Two people can make exactly the same change.
- Two people correct a misspelled group name exactly the same way.
Most importantly only work on what is assigned to you in dotproject, and if more than one contributor is assigned to the same file make sure you communicate about who is going to do what. If in doubt feel free to ask someone on the forum.
Tips
- Do not copy or drag folders in your svn folders.
Copying files to use them as a template for a new file is ok, but if you try to copy a whole folder you will mess stuff up.
- Right click in the space next to the commit button and choose “Locate on disk” to explore the two data you have received with the update command.
- Task Specific Update
If you want to start on a task right away and don’t want to wait for a full update, you can do the folowing.
- Update the parent folder that contains the file(s) for task you were assigned.
- Load the project or other file(s) needed for your task. If it asks for any files navigate as far down the path it is looking for as you can and then update that folder. Then continue looking for that file.
- Once everything is loaded save your project and start a full update while you work.
- When the update is done save and reload your project, this is in case a linked file that your work depends on was modified in the update. Double check your work to see if any updated files affected you.