NifTools/Using SVN

From NifTools

Jump to: navigation, search

Subversion, abbreviated as SVN, is a system for keeping all the members of a programming project in sync. It allows them to check in changes that are automatically received by the other members of the project when they update. So basically, it's the way to get the latest bleeding edge code that may not be fit for release. If it fixes a problem you have right now and you don't want to wait for the next release, it may be your best bet. The other projects that use Niflib also sometimes jump ahead rather than waiting for a release and use development code, so if you want to compile them yourself you will need to use SVN. Finally, if you want to contribute to the project, we'll want you to be working on the latest code so your patches are easy to apply.

Contents

SVN URLs

SVN uses a URL system for determining which files you want to download. You can check out all NifTools code by using this SVN URL:

https://niftools.svn.sourceforge.net/svnroot/niftools/trunk

If you're only interested in one project, you can check out only the code for that project.

Here are our current modules along with the SVN URL used to check them out:

Note that there are some dependencies between the different projects. For example, niflib and nifskope depend on docsys. In turn, max, maya, and niflyze depend on niflib. Unless you are really short on bandwith, it is easiest to check out the whole trunk (i.e. all of the code) in a single checkout from https://niftools.svn.sourceforge.net/svnroot/niftools/trunk, regardless from the project you want to work on, especially if you plan on compiling.

Windows

These steps will describe an easy to use SVN program for Windows called TortoiseSVN. If you already know how to use SVN and have another program that you like to use, or prefer to use it through the command line, those methods are fine and you probably don't need to read any further.

The first step is to Download and install TortoiseSVN

Once you have it installed, TortoiseSVN alters the right-click menu in Windows Explorer (the windows that show the contents of folders when you open them).

Checking out code

  • Create a new folder called 'niftools' or the name of the module if you're checking them out separately.
  • Open the folder you created so you have a window for it on the screen.
  • Right-click in the blank Folder window and choose SVN Checkout
  • For URL of Repository, enter the SVN URL that is given above for the code you want to check out and store in this folder.
  • Press OK
  • Wait a few moments while the files are downloaded.

Reading log messages

To read all log messages that relate to files in a specific folder or file:

  • Right-click the folder icon and choose TortoiseSVN->Show log

To read the messages that relate to a specific file, do the same thing but start by right-clicking the icon for that file.

At the bottom of the log, when you click each revision, you will see a list of the files that were changed. You can right click the entries in this list to save out that particular version of that file.

Updating to the latest code

Once you have the SVN folder created for the first time, you never need to enter the URL again. Just right-click the folder and choose SVN Update. All the files inside that have changed will be updated automatically.

Personal tools