Editing MG/Getting The Code
Jump to navigation
Jump to search
Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.
The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision | Your text | ||
Line 1: | Line 1: | ||
− | [[MegaGlest]] has switched to git for managing the game's source code and data (the svn repo is no longer active). | + | [[MegaGlest]] has now switched to git for managing the game's source code and data (the svn repo is no longer active). Using the command line you would get the code in one of two ways. Either read-only if you will not contribute changes or read and write if you plan to help contribute to the project as well. |
− | == | + | ==Choose a git client== |
− | + | The MegaGlest source is stored in a Git repository (versions prior to 3.9.0 are in a different SVN repository, however), and requires a Git client to download. Clients exist for all major operating systems. | |
− | + | ====Linux==== | |
− | + | Install the git tools. On Debian GNU/Linux based distributions this is as easy as | |
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | == | ||
− | |||
− | |||
− | = | ||
− | On Debian GNU/Linux based distributions this is as easy as | ||
sudo apt-get update && sudo apt-get install git | sudo apt-get update && sudo apt-get install git | ||
− | On other distributions, the process will be quite similar but you will need to use the package management tools available there | + | On other distributions, the process will be quite similar but you will need to use the package management tools available there. |
− | ===Windows=== | + | ====Windows==== |
− | Download [http://git-scm.com/ | + | Download [http://git-scm.com/ Git] and install it, then run <tt>git-bash.bat</tt> in the installation folder to start the Git command line. For those with a preference for a client with a graphical interface, [http://code.google.com/p/tortoisegit/ TortoiseGit] exists for that, though you will still need to install Git as well as [http://code.google.com/p/msysgit/ MysisGit]. |
− | |||
− | For those with a preference for a client with a graphical interface, | ||
==Check out the source code== | ==Check out the source code== | ||
===Cloning the sources=== | ===Cloning the sources=== | ||
− | '''''Prior to running these commands, you need to navigate to the directory (folder) you wish to place the MegaGlest source | + | :'''''Prior to running these commands, you need to navigate to the directory (folder) you wish to place the MegaGlest source in.''''' |
− | + | ====Read only==== | |
− | git clone -- | + | git clone --recursive [https://github.com/MegaGlest/megaglest-source https://github.com/MegaGlest/megaglest-source.git] |
− | |||
− | |||
− | |||
cd megaglest-source | cd megaglest-source | ||
git submodule update --init --recursive | git submodule update --init --recursive | ||
− | |||
− | === | + | ====Read and write==== |
− | + | # This will ask for your standard GitHub username and password | |
+ | git clone [https://github.com/MegaGlest/megaglest-source https://github.com/MegaGlest/megaglest-source.git] | ||
cd megaglest-source | cd megaglest-source | ||
+ | # This may ask for your standard GitHub username and password again | ||
+ | git submodule update --init --recursive | ||
cd data/glest_game | cd data/glest_game | ||
− | git checkout | + | git checkout master |
cd ../.. | cd ../.. | ||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
− | |||
==Tags and branches== | ==Tags and branches== | ||
− | Each release is 'tagged' and resides as '''tags''', so if you wanted an older release you would check out something below instead. Check [https:// | + | This will check out the '''master''' source code and data directories, which is where active development takes place in. Each release is 'tagged' and resides as '''tags''', so if you wanted an older release you would check out something below instead. Check [https://megaglest.svn.sourceforge.net/svnroot/megaglest/tags/ here] to see which ones are available. |
− | Branches are created | + | Branches are created in the '''branches''' subdirectory when required to seperate larger changes from active / stable development, so replace 'trunk' by 'branches' and check with your web brower which ones are available if this is your intention. |
==See also== | ==See also== | ||
*[[MG/Project Structure|Project Structure]] | *[[MG/Project Structure|Project Structure]] | ||
− | |||
− | |||
[[Category:MG]] | [[Category:MG]] | ||
− |