Subversion

Setup instructions for Subversion

What is subversion?

It's a system for hosting files and managing different versions of those files as they are modified/further developed. If you've heard of Git before, it's kinda like that, except it manages whole-file changes, instead of Git which intelligently manages line-by-line diffs.

Why use subversion (SVN)?

We're gonna need some way to share files between team members in the CAD department, and we want to avoid the pass-a-flash-drive-around method. Subversion allows for teams to develop their own individual parts and track different versions of those files on a central server that is shared among everyone on the team.

What should I look out for?

  • DO NOT modify an assembly that someone else is also working on -- Subversion is not like Git, so same-file version conflicts can only be resolved by choosing one version over another
  • DO commit your changes ASAP after you make modifications to the repository
  • DO write useful messages describing what changes you made

How do I set this up/use it?

Get your credentials

  • FIRST: Message Comran on Slack to set up a username/password on the SVN server
Your password should not be one that you use anywhere else.
Make sure that it is longer than 6 characters! Our server has gotten hacked before...

Download/Install Tortoise SVN (Windows ONLY)

Download Tortoise SVN (a GUI client for Subversion)

Svn Step 1

Go through the default install process (don't select any fancy options)

  • You will be prompted to close Firefox/Windows Explorer to proceed with installation. Make sure that the installation is performed at a convenient time so that this can occur.

Svn Step 2
Svn Step 3
Svn Step 4

Make a new folder within Documents called "uas-at-ucla_cad"

Svn Step 5

Go inside that folder, right-click, and select "SVN Checkout"

Svn Step 6

Fill in the UAS@UCLA SVN repository

  • URL of repository: svn://your_username@svn.uasatucla.org/cad
  • Replace your_username with your username!

Svn Step 7

Click OK, enter your user/pass that you set up earlier, wait for everything to download, and click OK

  • This will take a while. Pro-tip: Use Boelter Hall wifi for ridiculous download speeds.

Svn Step 8

Commit your first Solidworks part

Now you've got SVN running on your machine! Now prove that you have it set up by checking in a new Solidworks part...

Create a new solidworks part and saving it to the sandbox directory in the uas-at-ucla_cad folder (name it something like "firstname-lastname test part")

Svn Step 9
Svn Step 10
Svn Step 11
Svn Step 12

Find your new Solidworks part in the CAD folder, right click on it, and notify Subversion to start versioning the file.

Svn Step 13
Svn Step 14

Right click on the root CAD folder (not on any individual files) and Commit

  • Put in some useful commit message to describe the changes you made, like "Added a test part for [[your name here]]
  • Double check that you are only modifying the files that you intended to modify by looking at the "changes made" list, and click OK if it all looks good. Put a checkmark next to all the files that you intend to add/modify

Svn Step 15
Svn Step 16
Svn Step 17

Congrats, you successfully uploaded your first part!

Updating to the latest version on the server

Go to the uas-uat-ucla_cad folder, right click, and click on "SVN update"

Svn Step 18
Svn Step 19

Oh no something went wrong...

Occasionally, you may get a message like this:

Svn Step 20

This indicates that you interrupted the Subversion client in the past and a lock was never removed from the repository resource when updating or committing. To fix this, do a SVN cleanup:

Svn Step 21
Svn Step 22
Svn Step 23

Other issues? Google the errors first to see if online resources can remedy your problem. If all else fails, message me (Comran) on Slack, and please be sure to update this wiki page with the new information to help other UAS members in the future.

Happy CADing!