Difference between revisions of "HowTo:Checkout SVN"
(→Modules: Updated info about masters and ogre port) |
(Updated Checkout page) |
||
Line 12: | Line 12: | ||
Subversion, or SVN, is a mechanism by which developers can keep track of changes to their code and distribute these changes to the public in real time. This allows people to take advantage of software as it is being developed, between official releases. | Subversion, or SVN, is a mechanism by which developers can keep track of changes to their code and distribute these changes to the public in real time. This allows people to take advantage of software as it is being developed, between official releases. | ||
− | [[HowTo:Checkout_SVN#Windows_Clients|Windows users]] can use an [[HowTo:Checkout_SVN#Tortoise_SVN|SVN client]] to check out the | + | [[HowTo:Checkout_SVN#Windows_Clients|Windows users]] can use an [[HowTo:Checkout_SVN#Tortoise_SVN|SVN client]] to check out the "win32" module, which contains game data and windows binaries. |
[[HowTo:Checkout_SVN#Linux_Clients|Linux]] and [[HowTo:Checkout_SVN#Mac_OS_X_Clients|Mac OS X]] users must use an SVN client to check out the vegastrike module as well, which contains source code for them to compile. (Note that compiling Vega Strike on Mac OS X is considered very difficult.) | [[HowTo:Checkout_SVN#Linux_Clients|Linux]] and [[HowTo:Checkout_SVN#Mac_OS_X_Clients|Mac OS X]] users must use an SVN client to check out the vegastrike module as well, which contains source code for them to compile. (Note that compiling Vega Strike on Mac OS X is considered very difficult.) | ||
Line 30: | Line 30: | ||
Vega Strike's SVN repository holds several subdirectories, which can either be checked out separately or altogether. The most notable ones are included below. | Vega Strike's SVN repository holds several subdirectories, which can either be checked out separately or altogether. The most notable ones are included below. | ||
− | * ''' | + | * '''data''' - data files of the game. This consists mainly of models, textures and backgrounds. Required to play the game. |
+ | * '''win32''' - Windows Binaries as well as includes an "external" to the data directory. | ||
+ | * '''mac''' - Macintosh Package, as well as an "external" to the data directory. | ||
* '''masters''' - The original master files that created the game data (original meshes and uncompressed textures). | * '''masters''' - The original master files that created the game data (original meshes and uncompressed textures). | ||
* '''history''' - Old descriptions of factions and species. | * '''history''' - Old descriptions of factions and species. | ||
Line 40: | Line 42: | ||
* '''vegastrike''' - the game base code. | * '''vegastrike''' - the game base code. | ||
* '''data6.x''' - Data for the [[Development:Ogre|Ogre port]]. You may download the OGRE branch using this URL: http://vegastrike.svn.sourceforge.net/svnroot/vegastrike/branches/ogre_branch/ | * '''data6.x''' - Data for the [[Development:Ogre|Ogre port]]. You may download the OGRE branch using this URL: http://vegastrike.svn.sourceforge.net/svnroot/vegastrike/branches/ogre_branch/ | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
The Subversion tree can be browsed via a web interface: http://vegastrike.svn.sourceforge.net/viewvc/vegastrike/ | The Subversion tree can be browsed via a web interface: http://vegastrike.svn.sourceforge.net/viewvc/vegastrike/ | ||
Line 74: | Line 65: | ||
<pre> | <pre> | ||
− | svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk vegastrike | + | svn co --ignore-externals https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk vegastrike |
</pre> | </pre> | ||
...will download the entire tree (all modules) into directory `vegastrike'. But '''don't do this'''! Such a command would download data for both the normal and ogre branches, plus Visual Studio projects for ALL supported versions and goodness knows what else. | ...will download the entire tree (all modules) into directory `vegastrike'. But '''don't do this'''! Such a command would download data for both the normal and ogre branches, plus Visual Studio projects for ALL supported versions and goodness knows what else. | ||
− | You should really only download individual modules, and a similar syntax can be used. For example, to download the | + | You should really only download individual modules, and a similar syntax can be used. For example, to download the data module, |
<pre> | <pre> | ||
− | svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/ | + | svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/data data |
</pre> | </pre> | ||
...will suffice. (Leaving off the target directory will make svn try check out into the ''working directory''.) | ...will suffice. (Leaving off the target directory will make svn try check out into the ''working directory''.) | ||
In order to get all the files required to compile the game, checkout the following modules: | In order to get all the files required to compile the game, checkout the following modules: | ||
− | * | + | * data |
* vegastrike | * vegastrike | ||
==Tutorial to download, setup and run the development version== | ==Tutorial to download, setup and run the development version== | ||
− | In order to run the development version of Vega Strike, the executables expect to find the data to be in certain places relative to them. This short tutorial deals with these specifics on Linux operating systems. ( | + | In order to run the development version of Vega Strike, the executables expect to find the data to be in certain places relative to them. This short tutorial deals with these specifics on Linux operating systems. (more experienced MacOSX users can this, or they can read [[HowTo:Checkout_SVNMac]] |
So, let's start. | So, let's start. | ||
Line 103: | Line 94: | ||
If you run into any problems, it will work fine to follow the instruction below, using svn to do the whole checkout. | If you run into any problems, it will work fine to follow the instruction below, using svn to do the whole checkout. | ||
− | * Download (check-out) the source code package ''vegastrike'', and the content package '' | + | * Download (check-out) the source code package ''vegastrike'', and the content package ''data'' package. |
<pre>~/VegaStrike> svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/vegastrike | <pre>~/VegaStrike> svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/vegastrike | ||
− | ~/VegaStrike> svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/ | + | ~/VegaStrike> svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/data</pre> |
This leaves you with three new directories inside your Vega Strike directory called as the packages are. | This leaves you with three new directories inside your Vega Strike directory called as the packages are. | ||
Line 118: | Line 109: | ||
===Setup=== | ===Setup=== | ||
− | To run Vega Strike, the built executables need all the configuration and data files to be in the right place relative to them. Currently, the executables (''vegstrike'' and '' | + | This step is not necessary--the binaries will figure out where they are with respect to the data directory. |
− | * Change in to the '' | + | |
− | <pre>~/VegaStrike/vegastrike> cd ../ | + | To run Vega Strike, the built executables need all the configuration and data files to be in the right place relative to them. Currently, the executables (''vegstrike'' and ''vssetup'') reside in the source code directory. But they can be run out of the ''data'' directory. Therefore, we will create a link. |
+ | * Change in to the ''data'' directory. (We are still in the source code directory ''vegastrike''.) | ||
+ | <pre>~/VegaStrike/vegastrike> cd ../data</pre> | ||
* Create symbolic links to the executables in the source code directory. | * Create symbolic links to the executables in the source code directory. | ||
− | <pre>~/VegaStrike/ | + | <pre>~/VegaStrike/data> ln -s ../vegastrike/vegastrike |
− | ~/VegaStrike/ | + | ~/VegaStrike/data> ln -s ../vegastrike/vssetup</pre> |
− | + | * After that, you must run "'''./vssetup'''" inside the '''data''' folder, or any folder which has the correct '''setup.config''' and '''vegastrike.config'''. | |
− | * After that, you must run "'''./vssetup'''" inside the ''' | ||
If we had made copies or moved the files instead of symbolic linking, we would have to do the procedure of copying or moving every time we build the executables from source. | If we had made copies or moved the files instead of symbolic linking, we would have to do the procedure of copying or moving every time we build the executables from source. | ||
===Running and configuring=== | ===Running and configuring=== | ||
− | * To run Vega Strike you have to start it from the '' | + | * To run Vega Strike you have to start it from the ''data'' directory. |
− | <pre>~/VegaStrike/ | + | <pre>~/VegaStrike/data> ./vegastrike</pre> |
− | * Optionally you can create a short cut to this application onto your desktop or in your start menu. Simply point it to the ''vegastrike'' executable | + | * Optionally you can create a short cut to this application onto your desktop or in your start menu. Simply point it to the ''vegastrike'' executable. |
− | * If you need to adjust screen resolutions, input devices and key-mappings, do so by editing the configuration file ''vegastrike.config''. The default configuration file resides in the '' | + | * If you need to adjust screen resolutions, input devices and key-mappings, do so by editing the configuration file ''vegastrike.config''. The default configuration file resides in the ''data'' directory. You can change that or you can make your own user specific version by first copying it into your ''.vegastrike'' (hidden directory) directory in your user's home directory. |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
===Staying updated with the development version=== | ===Staying updated with the development version=== | ||
As development progresses the repository changes. In order to update your working copy you need to do the following. | As development progresses the repository changes. In order to update your working copy you need to do the following. | ||
− | * Change into the package's directory you want to update. In our example all the packages were stored in a directory called ''VegaStrike''. Let's assume we want to update the '' | + | * Change into the package's directory you want to update. In our example all the packages were stored in a directory called ''VegaStrike''. Let's assume we want to update the ''data'' package. |
<pre>~> cd VegaStrike | <pre>~> cd VegaStrike | ||
− | ~/VegaStrike> cd | + | ~/VegaStrike> cd data</pre> |
* Update from the SVN repository. | * Update from the SVN repository. | ||
− | <pre>~/VegaStrike/ | + | <pre>~/VegaStrike/data> svn update</pre> |
− | * Do this for every package you want to update. Exchange '' | + | * Do this for every package you want to update. Exchange ''data'' with ''vegastrike''. |
− | * If something changed in the '' | + | * If something changed in the ''data'' package, you don't need to recompile. |
* If something changed in the source code package ''vegastrike''. You only need to repeat the building part of this tutorial and in case you did not create symbolic links the copying or moving procedure for the executables in the setup part of this tutorial. You should not need to type "make clean", however if you experience errors like "unresolved external symbol" it may remedy that error. | * If something changed in the source code package ''vegastrike''. You only need to repeat the building part of this tutorial and in case you did not create symbolic links the copying or moving procedure for the executables in the setup part of this tutorial. You should not need to type "make clean", however if you experience errors like "unresolved external symbol" it may remedy that error. | ||
=Windows Clients= | =Windows Clients= | ||
− | Note: For windows, only the ''' | + | Note: For windows, only the '''win32''' module is necessary to play the game. It will download the "data" directory You will find the executable program inside the "bin" folder. |
If you are interested in compiling the code, you will need the '''vegastrike''' module, as well as the appropriate vega-project module for your Visual C++ version. See [[HowTo:VCPP_Compiling]] for compiling info. | If you are interested in compiling the code, you will need the '''vegastrike''' module, as well as the appropriate vega-project module for your Visual C++ version. See [[HowTo:VCPP_Compiling]] for compiling info. | ||
Some people have problems with the latest executable relating to Visual C++ 8. If you want an older version of the executable compiled with VC7, you can browse the repository here: | Some people have problems with the latest executable relating to Visual C++ 8. If you want an older version of the executable compiled with VC7, you can browse the repository here: | ||
− | http://vegastrike.svn.sourceforge.net/viewvc/vegastrike/trunk/ | + | http://vegastrike.svn.sourceforge.net/viewvc/vegastrike/trunk/win32/bin/vegastrike.exe?view=log |
==Tortoise SVN== | ==Tortoise SVN== | ||
Line 173: | Line 159: | ||
* Download and Install Tortoise SVN from http://tortoisesvn.tigris.org | * Download and Install Tortoise SVN from http://tortoisesvn.tigris.org | ||
* Create a new folder in Windows Manager where you will download your modules (called Sandbox, SVN or similar working location name); | * Create a new folder in Windows Manager where you will download your modules (called Sandbox, SVN or similar working location name); | ||
− | * Within that folder, create another folder | + | * Within that folder, create another folder (VegaStrike); |
* Right click on the folder created and select SVN Checkout. This brings up the checkout configuration screen; | * Right click on the folder created and select SVN Checkout. This brings up the checkout configuration screen; | ||
− | * Input the URL of the repository into the dialog box | + | * Input the URL of the repository into the dialog box: |
<pre> | <pre> | ||
− | https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/ | + | https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/win32 |
</pre> | </pre> | ||
**You may also use the built-in repository browser to select the module you wish to check out. | **You may also use the built-in repository browser to select the module you wish to check out. | ||
Line 184: | Line 170: | ||
=Mac OS X Clients= | =Mac OS X Clients= | ||
+ | |||
+ | NOTE: Leopard (10.5) comes with a SVN client. | ||
==Command Line Client== | ==Command Line Client== | ||
Line 222: | Line 210: | ||
==Building== | ==Building== | ||
+ | |||
+ | Note, if you are not interested in compiling your own version, see [[HowTo:Checkout_SVNMac]] to get the whole package. | ||
+ | |||
'''→''' ''See [[HowTo:Compile on OSX]]'' | '''→''' ''See [[HowTo:Compile on OSX]]'' | ||
Revision as of 05:15, 2 May 2008
Edit News | HowTos | Compiling with VCPP |
If you're interested in an experimental version of Vega Strike, then SVN is what you'll be looking at.
Executive summary
Subversion, or SVN, is a mechanism by which developers can keep track of changes to their code and distribute these changes to the public in real time. This allows people to take advantage of software as it is being developed, between official releases.
Windows users can use an SVN client to check out the "win32" module, which contains game data and windows binaries.
Linux and Mac OS X users must use an SVN client to check out the vegastrike module as well, which contains source code for them to compile. (Note that compiling Vega Strike on Mac OS X is considered very difficult.)
Contents
What is SVN?
SVN stands for Subversion, a system similar to CVS. It allows developers to simultaneously work on a centralised project - in this case, that's Vega Strike.
Downloading ("checking out") and compiling the SVN-version often gives you access to features not included in the latest stable release of the program. SVN-based versions can be unstable and may not even work at all, but may hold advantages compared to stable versions.
Structure
Unlike a CVS repository, the top level of an SVN repository contains more than just the trunk. Vega Strike's SVN repository follows the standard layout, so the SVN root looks like this:
- branches - Independent copies of some or all of the trunk code. A developer making major changes, such as the ogre branch or major code cleanup will usually make a branch so they can keep track of their progress without breaking the trunk code for everyone else. These changes eventually are merged back into the trunk.
- tags - Revisions which have been marked. For instance, a tag might be made for a stable release so that svn users can update to it via the svn sw command. The VS developers like to use tags to mark milestones in the code, such as before or after a major change, so you'll see a lot of tags.
- trunk - The main trunk code, as would be seen in the root of a CVS repository. This contains a number of modules filled with code and data.
Modules
Vega Strike's SVN repository holds several subdirectories, which can either be checked out separately or altogether. The most notable ones are included below.
- data - data files of the game. This consists mainly of models, textures and backgrounds. Required to play the game.
- win32 - Windows Binaries as well as includes an "external" to the data directory.
- mac - Macintosh Package, as well as an "external" to the data directory.
- masters - The original master files that created the game data (original meshes and uncompressed textures).
- history - Old descriptions of factions and species.
- modtools - Tools to aid creation and modification of game files (campaigns and units)
- translations - Translations of Vega Strike data files into other languages.
- vega-proj - Deprecated Visual C++ 6 projects. (See HowTo:VCPP_Compiling#Visual_C.2B.2B_6.0_.28deprecated.29 here)
- vega-vc7 - Visual Studio 7 projects. (See HowTo:VCPP_Compiling#Visual_Studio_7.x here
- vega-vc8 - Visual Studio Express 2005 projects. (See HowTo:VCPP_Compiling#Visual_C.2B.2B_8.0_.282005_Express.29 here)
- vegastrike - the game base code.
- data6.x - Data for the Ogre port. You may download the OGRE branch using this URL: http://vegastrike.svn.sourceforge.net/svnroot/vegastrike/branches/ogre_branch/
The Subversion tree can be browsed via a web interface: http://vegastrike.svn.sourceforge.net/viewvc/vegastrike/
→ See also: Development:CVS Tree
Linux Clients
Command-line svn
Website
Description
The linux-command `svn' is the most basic Subversion client.
Using svn for downloading vs-devel
Checking out (downloading) the Vega Strike svn-modules is easy. The general syntax is
svn co [repo]/trunk/[module] [target-directory]
svn co --ignore-externals https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk vegastrike
...will download the entire tree (all modules) into directory `vegastrike'. But don't do this! Such a command would download data for both the normal and ogre branches, plus Visual Studio projects for ALL supported versions and goodness knows what else.
You should really only download individual modules, and a similar syntax can be used. For example, to download the data module,
svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/data data
...will suffice. (Leaving off the target directory will make svn try check out into the working directory.) In order to get all the files required to compile the game, checkout the following modules:
- data
- vegastrike
Tutorial to download, setup and run the development version
In order to run the development version of Vega Strike, the executables expect to find the data to be in certain places relative to them. This short tutorial deals with these specifics on Linux operating systems. (more experienced MacOSX users can this, or they can read HowTo:Checkout_SVNMac
So, let's start.
- Create a directory where you would like your copy of the Vega Strike development version to live in. For example purposes we will create a directory called VegaStrike in our user's home-directory.
~> mkdir VegaStrike
- Change into this newly created directory. In our case:
~> cd VegaStrike
Initial downloading (check-out)
Now we can start downloading the packages from the SVN repository. If you download them directly into your Vega Strike directory they will be just in the right place.
To save on download bandwidth, you can download a snapshot of the SVN tree, and then just update that to the current revision. One big compressed file will download much faster than having SVN get each file individually. Snapshots available here: http://vegastrike.sourceforge.net/forums/viewtopic.php?t=6749. Also here (not sure if this second one includes the .svn directories needed to update it with svn): http://sourceforge.net/project/showfiles.php?group_id=181552&package_id=211092&release_id=463105. If you run into any problems, it will work fine to follow the instruction below, using svn to do the whole checkout.
- Download (check-out) the source code package vegastrike, and the content package data package.
~/VegaStrike> svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/vegastrike ~/VegaStrike> svn co https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/data
This leaves you with three new directories inside your Vega Strike directory called as the packages are.
Note: If you are having problems with SVN due to connecting via a proxy, try to solve them using the method described here: http://subversion.tigris.org/faq.html#proxy
Building
FIXME This should merged with the HowTo:Compile_from_SVN page. (Partially done)
The HowTo:Compile_from_SVN page has a list of some options that you can pass to ./configure
Setup
This step is not necessary--the binaries will figure out where they are with respect to the data directory.
To run Vega Strike, the built executables need all the configuration and data files to be in the right place relative to them. Currently, the executables (vegstrike and vssetup) reside in the source code directory. But they can be run out of the data directory. Therefore, we will create a link.
- Change in to the data directory. (We are still in the source code directory vegastrike.)
~/VegaStrike/vegastrike> cd ../data
- Create symbolic links to the executables in the source code directory.
~/VegaStrike/data> ln -s ../vegastrike/vegastrike ~/VegaStrike/data> ln -s ../vegastrike/vssetup
- After that, you must run "./vssetup" inside the data folder, or any folder which has the correct setup.config and vegastrike.config.
If we had made copies or moved the files instead of symbolic linking, we would have to do the procedure of copying or moving every time we build the executables from source.
Running and configuring
- To run Vega Strike you have to start it from the data directory.
~/VegaStrike/data> ./vegastrike
- Optionally you can create a short cut to this application onto your desktop or in your start menu. Simply point it to the vegastrike executable.
- If you need to adjust screen resolutions, input devices and key-mappings, do so by editing the configuration file vegastrike.config. The default configuration file resides in the data directory. You can change that or you can make your own user specific version by first copying it into your .vegastrike (hidden directory) directory in your user's home directory.
Staying updated with the development version
As development progresses the repository changes. In order to update your working copy you need to do the following.
- Change into the package's directory you want to update. In our example all the packages were stored in a directory called VegaStrike. Let's assume we want to update the data package.
~> cd VegaStrike ~/VegaStrike> cd data
- Update from the SVN repository.
~/VegaStrike/data> svn update
- Do this for every package you want to update. Exchange data with vegastrike.
- If something changed in the data package, you don't need to recompile.
- If something changed in the source code package vegastrike. You only need to repeat the building part of this tutorial and in case you did not create symbolic links the copying or moving procedure for the executables in the setup part of this tutorial. You should not need to type "make clean", however if you experience errors like "unresolved external symbol" it may remedy that error.
Windows Clients
Note: For windows, only the win32 module is necessary to play the game. It will download the "data" directory You will find the executable program inside the "bin" folder.
If you are interested in compiling the code, you will need the vegastrike module, as well as the appropriate vega-project module for your Visual C++ version. See HowTo:VCPP_Compiling for compiling info.
Some people have problems with the latest executable relating to Visual C++ 8. If you want an older version of the executable compiled with VC7, you can browse the repository here: http://vegastrike.svn.sourceforge.net/viewvc/vegastrike/trunk/win32/bin/vegastrike.exe?view=log
Tortoise SVN
Website
http://tortoisesvn.tigris.org/
Description
Just like TortoiseCVS, Tortoise SVN lets you work with files under SVN version control directly from Windows Explorer. It's freely available under the GPL.
With TortoiseSVN you can directly check out modules, update, commit and see differences by right clicking on files and folders within Explorer. You can see the state of a file with overlays on top of the normal icons within Explorer. It even works from within the file open dialog.
Usage
- Download and Install Tortoise SVN from http://tortoisesvn.tigris.org
- Create a new folder in Windows Manager where you will download your modules (called Sandbox, SVN or similar working location name);
- Within that folder, create another folder (VegaStrike);
- Right click on the folder created and select SVN Checkout. This brings up the checkout configuration screen;
- Input the URL of the repository into the dialog box:
https://vegastrike.svn.sourceforge.net/svnroot/vegastrike/trunk/win32
- You may also use the built-in repository browser to select the module you wish to check out.
- Click OK to begin checkout of the module.
[Edit - Turbo: The download is 600+ MB and will take some time. I did not have to install the program -- after downloading, run the Setup program in the BIN folder, then you can run VEGASTRIKE.EXE to play.]
Mac OS X Clients
NOTE: Leopard (10.5) comes with a SVN client.
Command Line Client
Website
http://metissian.com/projects/macosx/subversion/
(or http://pdb.finkproject.org/pdb/search.php?summary=svn for Fink packages.)
Footnote: metissian.com does not maintain current binaries. A better source would be (ordered from most current to most convenient):
(a) http://subversion.tigris.org/ for current source code.
(b) use Fink or MacPorts to get (usually) current source code.
(c) http://www.codingmonkeys.de/mbo/ for a (usually) current install package.
(d) XCode3 includes svn as part of the default installation (But not XCode2).
SCPlugin
Website
Description
"The goal of the SCPlugin project is to integrate Subversion into the Mac OS X Finder. The inspiration for this project came from the TortoiseSVN project."
Usage
Must have command line client installed.
FIXME -WRITEME
Other
Building
Note, if you are not interested in compiling your own version, see HowTo:Checkout_SVNMac to get the whole package.
→ See HowTo:Compile on OSX
Edit News | HowTos | Checkout CVS |