Version Control using Subversion
This class uses subversion to check out and hand-in assignments and you get automatic access about 12-24 hours after joining the class. Your subversion home directory should be the following replacing 'yournetid' with your netid:
https://subversion.ews.illinois.edu/svn/sp17-cs126/yournetid
There is a public _shared subdirectory that you can read (but not write) -
https://subversion.ews.illinois.edu/svn/sp17-cs126/_shared
You can access these resources three ways: (1) using svn tools in your terminal shell, (2) from IntelliJ IDE, and (3) using your web browser (for read only access).
Using subversion with IntelliJ IDEA
IntelliJ IDEA has subversion support built right in. Do the following to get a project checked into subversion.
Step 1: Configure IntelliJ (only needs to be done once)
- Navigate to Preferences
- Navigate to Version Control->Subversion
- Set your 'User name' to your netid
- Click 'Password'
- Click OK
Depending on your operating system, you made need to make sure that a copy of 'ssh' (secure shell) is installed.
Step 2: Checking a project into IntelliJ the first time
If you have created an existing project in IntelliJ, the process below can get it checked into subversion.
- Navigate to VCS->Import into Version Control->Import into Subversion
- Click the + symbol to add a new Subversion repository.
Enter the following in the text box, replacing 'yournetid' with your netid, and 'ProjectName' with the name of your project (no spaces)
https://subversion.ews.illinois.edu/svn/sp17-cs126/yournetid/week1/ProjectName
- Click Import
- I think it is okay to un-select 'Include ignored resources'
- Type a commit message in, like 'initial commit'.
- Click OK
Step 3: Navigate to your SVN using your web browser to make sure that the check in was successful
At this point, you've copied what is in your project into SVN, but your local copy isn't under version control.
Step 4: Checking your project out so that you can make future commits
- VCS -> Checkout from Version Control -> Subversion
- Select the directory that you imported into -> Checkout
- Select your project directory(should already be selected) -> Okay
- Keep all the defaults on this next prompt -> OK
- Upgrade automatically(use Subversion 1.7) -> OK
- Yes
Other subversion/IntelliJ Tips:
Though there are a few 'gotchas' we'll mention here, using subversion with IntelliJ is very similar to using subversion with other IDEs such as Eclipse. Here's some quick tips-
- Installation woes? Don't panic... Web searches are very useful when installing new software. Usually someone before you has encountered a similar problem and has figured out how to solve it
- You can access subversion two different ways: From the 'Version Control System' (VCS) menu and using the context menu ("right" or "CTRL" clicking on the project or specific file)
- IntelliJ stores its projects inside your user directory under IdeaProjects. Don't be surprised if you have to navigate to there when first importing a project.
- Top tip! You can create a new subdirectory for your project when you check it in, as we did above with 'ProjectName'. If you don't do this, all of your project files are put directly inside the top-most directory. After importing you will need to commit again to ensure all changes are uploaded to the server.
- Use the VCS menu item Checkout to get a local copy onto your laptop using an existing project that is already in subversion.
- Use the VCS menu item Commit changes when you are ready to send your local edits back to the Subversion server.
- Top tip #2! If you stopped subversion part way through a task, you may need to use the 'Cleanup' menu item before it will work again.
- Top tip #3! Working hard? Use it! Made lots of changes? Save them! Commit your changes to subversion every hour, or more often if you've reached a good point. You can always go back to a previous version provided you saved it.