Get a clone of the repository
To get the source code of TYPO3, clone the repository git://git.typo3.org/Packages/TYPO3.CMS.git On the command line, you can use
git clone git://git.typo3.org/Packages/TYPO3.CMS.git
Cloning via HTTP is currently not available.
Cloning downloads the entire TYPO3 repository. By default, the master branch (customarily known as "trunk" from SVN) is checked out. If you want the current development version of another branch (e.g. TYPO3 4.5), you have to checkout that branch (more info on Branch (Git)).
Getting recent changes
To update your local branch, execute the following commands inside your clone:
Getting an older branch
To checkout an older branch, execute the following commands:
git checkout TYPO3_6-2 git pull
For TYPO3 4.5 the command looks like this:
git checkout TYPO3_4-5 git pull
As new tags are not fetched automatically by git pull, you have to do this on your own:
git fetch --tags
How to "SVN export" a Git repository
There is not such command in Git - it is not needed. All you have to do is:
- Checkout core.git
- Remove the subfolder .git (Your-Copy/.git)
rsync is a widely used tool to efficiently copy files. You can exclude the .git subfolder from being copied using --exclude:
rsync src/ dest/ --recursive --exclude '.git'
To delete files that don't exist in the destination folder, use the option --delete. This results in mirroring instead of copying.