- Some SVN tutorials are here, here, and here. You can also search svn tutorial and svn introduction for more.
- The traditional reference is the SVN book here, which includes HTML and PDF versions; you might want to start with Chapter 1. Svn is up to version 1.13 now, but nothing about our very basic use of svn has changed between 1.7 and 1.13.
- We will use Phoenixforge to manage the SVN repositories in the class. Authentication on Phoenixforge, and with the svn commands that connect to it, is with your University CNetID and its password.
- As a student in SciVis, you will be dealing with at least two different projects:
(“project” is Phoenixforge terminology for an organizational layer on top
of an SVN repository, or "repo").
- The "scivis-2024" project. This will be used to distribute canonical files to you, such as libraries and datasets. You won't be able to modify these files (or more precisely, you won't be able to commit any local changes you make to these files).
- A per-student sub-project named "CNETID-scivis-2024", where "CNETID" is your CNetID. You should see your per-student sub-project listed at the "scivis-2024" project (that listing of all students is not visible to anyone outside the class). You hand in work by adding and committing files to this svn repo. For each homework and project, we will create sub-directories within this project for you. You should not create new per-assignment directories inside CNETID-scivis-2024.
- If you partner with someone for one of the projects, a per-pair "CNETID1-CNETID2-scivis-2024" repository will be created for you. You will use this for any work that you complete as that pair, which may be multiple projects.
- The creation of per-student sub-projects within "scivis-2024" is done automatically and periodically, based on the electronically accessible course registration information at that time. Therefore, it may take a day or so for you to show up here, if you have added the class recently. Post a question in the “svn” Category on EdStem if you are having problems.
- We want to allow code in your per-student "CNETID-scivis-2024" repo (as well as in any per-pair repos) to refer to canonical files in the general "scivis-2024" class repo, rather than having you needlessly copy or hand-in those files, which complicates grading. We therefore use an environment variable $SCIVIS to identify where your scivis-2024 checkout is. Set $SCIVIS to the full path of your scivis-2024, ending with "scivis-2024".
- The easiest way to set this up is to create a directory that you'll use for for SciVis coding, such as with:
And thenmkdir scivis-work
Once you are in scivis-work or whatever directory you will use to contain your SciVis coding, you first checkout (shortened to co) the shared scivis-2024 repo:cd scivis-work
using your CNetID and its password. Then you set the SCIVIS environment variable (so that make in your project directory knows where to find the include and library files needed for compilation), and augment the PATH environment variable to find some executables (main unu) we use in the class:svn co https://phoenixforge.cs.uchicago.edu/svn/scivis-2024/
How PATH was augmented had to depend on the operating system, because executables (with the same name) for different platforms are in different directories. Then, this command checks out your own repo, after you replace "CNETID" with your CNetID:export SCIVIS=`pwd`/scivis-2024 if [[ $(uname -s) == "Darwin" ]]; then SFX="osx"; else SFX="linux"; fi export PATH=${PATH}:$SCIVIS/tpz/bin-$SFX
If you are using a department linux machines, or on your own computer, you're using the same home directory every time you log in, so the svn co commands only have to be run once; the files and directories will persist between logins. For the homework assignments that do not require any programming work, you will be handing in a PDF files, so it doesn't matter where you're running the svn commands.svn co https://phoenixforge.cs.uchicago.edu/svn/CNETID-scivis-2024/
When sitting in front of a CSIL Mac, however, a new home directory may be created each time you log in, so you will need to re-run the above commands each time you start work on a CSIL Mac. You must svn add and svn commit files you create here, or else your work can be lost from the CSIL Mac.
- To help with this, the above commands have been collected into a script:
scivis-setup.sh. After you log into a CSIL Mac,
you can download and run this with:
By using "source scivis-setup.sh" the changes made by the script to your SCIVIS and PATH environment variables will stay set in your current shell (while running ./scivis-setup.sh" will only set variables in a shell process that dies with the completion of the sript).curl -O http://people.cs.uchicago.edu/~glk/class/scivis/svn/scivis-setup.sh source scivis-setup.sh
- On your own laptop, or on linux.cs.uchicago.edu, or remote access to CSIL Macs, you may want a way to keep the SCIVIS and PATH environment variables set between logins. You can do this by copying the commands to set them into your ~/.bash_profile file, as described here. On your laptop you may have to modify a different "dotfile"; find a dotfile that is read in at the start of each shell.
- From then on you really only need to know three or four svn commands. You
execute these commands from within the directories created by the svn co
commands above.
- For scivis-2024, the only command you'll ever need is
svn update
- For your own CNETID-scivis-2024, you use
to get the per-assignment directories we create for you, and other per-assignment files we distribute (typically stubs or templates for the files you'll have to edit further). To hand-in file X, if an initial version was not already distributed to you, you need to firstsvn update
once, and then for all subsequent updates to X,svn add X
To see if you have local uncommitted changes, run:svn commit -m "descriptive message here" X
This lists files that have uncommitted changes (marked with an "M"), and files that have not been added or committed (marked with a "?"), called "untracked" files in SVN.svn status
- For scivis-2024, the only command you'll ever need is
- Because svn commit is how you are handing in your work, be
careful with it. Its proper use is your responsibility. In particular:
- If you haven't done an svn add and svn commit, it hasn't been handed in. Use svn status to see uncommitted changes and untracked files. Make sure that you have done an svn add on all the files you want to hand in.
- You should double check that the files you think you have handed in, have really been handed in. Associated with every per-student project is a web-based view of the SVN repo: https://phoenixforge.cs.uchicago.edu/projects/CNETID-scivis-2024/repository, but that URL won't actually work until you replace CNETID with your CNetID.
- To make this simpler, the directories in your individual CNETID-scivis-2024 will include a 00-checkme.html file that contains a link to a Phoenixforge web page showing the actual contents of that directory, on the SVN server. Use this link to confirm what we will get we collect your work for grading, and to ensure that you have not submitted an empty ("0 Bytes") file by accident.
- svn and the repos involved know nothing about deadlines: you can modify and commit files both before and after the deadline. For grading, we will collect files as they were committed by the deadline.