| | 1 | = Using Git for Orxonox = |
| | 2 | |
| | 3 | Git may be used by experienced users, who want to use Git's advanced features for developing Orxonox. |
| | 4 | |
| | 5 | == Initial Checkout == |
| | 6 | |
| | 7 | To checkout orxonox' [wiki:SVN]-Repository in Git use: |
| | 8 | |
| | 9 | {{{ |
| | 10 | git svn clone --stdlayout --prefix=svn/ https://svn.orxonox.net/game/code orxonox |
| | 11 | }}} |
| | 12 | |
| | 13 | This will check out the whole history of the Project code with all the branches and tags, it will use about 150 MB of disk space and it may take a long time (while checking out it will use more disk space, until things get automatically compressed by {{{git gc}}}). |
| | 14 | |
| | 15 | == Basic Configuration == |
| | 16 | |
| | 17 | Set your full name and email address: |
| | 18 | |
| | 19 | {{{ |
| | 20 | git config --global user.name "Your Name Comes Here" |
| | 21 | git config --global user.email you@yourdomain.example.com |
| | 22 | }}} |
| | 23 | |
| | 24 | Some fancy colors: |
| | 25 | |
| | 26 | {{{ |
| | 27 | git config --global color.ui auto |
| | 28 | }}} |
| | 29 | |
| | 30 | The --global argument tells git to store the config in .gitconfig in your home, so these will be usable for every git repository you have. |
| | 31 | |
| | 32 | Add something like this to your .bashrc for having a nice, git-aware bash prompt, which shows the current branch you are on and sometimes some other stuff: |
| | 33 | |
| | 34 | {{{ |
| | 35 | PS1='\u@\h:\w$(__git_ps1 " (%s)")\$ ' |
| | 36 | }}} |
| | 37 | |
| | 38 | == Basic Usage == |
| | 39 | |
| | 40 | Pull changes from SVN to your local Git Repository: |
| | 41 | |
| | 42 | {{{ |
| | 43 | git svn rebase |
| | 44 | }}} |
| | 45 | |
| | 46 | Commit local changes and push them to the SVN: |
| | 47 | |
| | 48 | {{{ |
| | 49 | git commit -a |
| | 50 | git svn dcommit |
| | 51 | }}} |
| | 52 | |
| | 53 | == Branches == |
| | 54 | |
| | 55 | TBD. |
| | 56 | |
| | 57 | == Documentation == |
| | 58 | |
| | 59 | To learn more about git see: http://git-scm.com/documentation |