= Getting the code = == Windows == === Git === * Download and install [https://tortoisegit.org/ TortoiseGit]. (Make sure you reboot when it asks you to.) === Subversion (SVN) === * Download and install [https://tortoisesvn.net/ TortoiseSVN]. (Make sure you check the "command line client tools" option and reboot when it asks you to.) == macOS == * Git is part of the `Xcode Command Line Tools` package, and can be installed via the GUI or the terminal. {{{ #!sh xcode-select --install }}} * SVN is no longer part of the `Xcode Command Line Tools` package, but can be installed, e.g. via [http://brew.sh Homebrew]. {{{ #!sh brew install svn }}} == Linux == === Git === `Git` is usually present on modern distributions of Linux however you might need to install it in some cases. Depending on your Linux flavour your package manager might differ. For instance on **Ubuntu** it would be: {{{ #!sh sudo apt update sudo apt install git }}} === Subversion (SVN) === You might need to have to install subversion for it to work. Depending on your Linux flavour your package manager might differ. For instance on **Ubuntu** it would be: {{{ #!sh sudo apt update sudo apt install subversion }}} == All platforms == You'll need approximatively **8GB** for a clean checkout, and a few more if you build and run the game. So try to have at least **20GB** free to be safe. '''Note:''' 0 A.D. is primarily developed on `SVN`. However since we are using Arcanist and [wiki:Phabricator], unless you have commit access you should never need to use `SVN` if you don't want to. You can use `Git` instead using mirrors, those may be slightly less up-to-date but usually offers faster downloads. Those mirrors are updated daily. '''Important:''' Make sure that the checkout directory doesn't contain special characters (spaces or non-ASCII characters) === Git === To use a `Git` mirror, use one of the following commands: {{{ #!sh git clone https://github.com/0ad/0ad.git }}} or {{{ #!sh git clone https://gitlab.com/0ad/0ad.git }}} As of February 2024, the Git repo consumes about 9 GB of disk space. Consider using `--depth=50` or something like that if you don't plan to compile previous versions. === Subversion (SVN) === To checkout the latest code from `SVN`, run this command: {{{ #!sh svn co https://svn.wildfiregames.com/public/ps/trunk/ 0ad }}} '''Note:''' This is the read-only public `SVN` URL. If you have commit access, you need to use this one instead: {{{ #!sh svn co https://svn.wildfiregames.com/svn/ps/trunk/ 0ad }}} '''Note:''' Sometimes `SVN` stops before it has downloaded all files. You should check that it outputs something like `at revision rXXXXX`. Otherwise run {{{ #!sh svn cleanup 0ad svn up 0ad }}}