| 1 | == The ROPP Repository == |
| 2 | |
| 3 | The whole ROPP development system is divided into three areas: |
| 4 | * '''ropp_src''' : deliverable code & supporting development system |
| 5 | * '''ropp_doc''' : user and project documentation |
| 6 | * '''ropp_test''' : Test Folder (test system and its results) |
| 7 | |
| 8 | The repository for ROPP can be accessed via the Subversion server at the URL |
| 9 | {{{ |
| 10 | https://svn.grassaf.org/ropp/ |
| 11 | }}} |
| 12 | For example, checking out the latest development (trunk) versions: |
| 13 | {{{ |
| 14 | svn checkout https://svn.grassaf.org/ropp/ropp_src/trunk . |
| 15 | svn checkout https://svn.grassaf.org/ropp/ropp_doc/trunk . |
| 16 | svn checkout https://svn.grassaf.org/ropp/ropp_test/trunk . |
| 17 | }}} |
| 18 | will check out the source code, documentation, and test folder, respectively to the local working directory. |
| 19 | |
| 20 | For a complete list of Subversion commands see the [http://svnbook.red-bean.com/en/1.0/index.html SVN reference manual] |
| 21 | |
| 22 | == Branches == |
| 23 | |
| 24 | Developments to ROPP should be made from, and committed to, a ''branch'' rather than directly to the latest trunk version. This allows changes to be tested before merging the required changes back into the trunk. The trunk therefore represents a stable 'next potential release' state for ROPP. Branches can be temporary and might be for working on resolving a specific Trac Ticket. |
| 25 | |
| 26 | '''Creating a branch''' |
| 27 | |
| 28 | To create a branch of ropp_src from the trunk use the ''svn copy SRC DST'' command: |
| 29 | {{{ |
| 30 | svn copy https://svn.grassaf.org/ropp/ropp_src/trunk https://svn.grassaf.org/ropp/ropp_src/branches/dev/Share/<branch_name> |
| 31 | }}} |
| 32 | where <branch name> is a name of your choice which should reflect what you are working on. |
| 33 | |
| 34 | By default it is assumed that you wish to branch from the latest change version of the trunk. The ''-r'' flag can be used to specify the trunk revision from which a branch is required if this is not the latest. The ''-m'' flag should be used when creating a branch to describe the contents of the branch. |
| 35 | {{{ |
| 36 | svn copy [-r revision] SRC DST [-m "some text here"] |
| 37 | }}} |
| 38 | |
| 39 | Similar branches may be created to store user versions of ropp_doc or ropp_test as required. |
| 40 | |
| 41 | '''Checking out a branch''' |
| 42 | |
| 43 | To make developments, the branch needs to be checked out to the local working directory for editing as above, specifying the path name for the required branch as |
| 44 | {{{ |
| 45 | svn checkout https://svn.grassaf.org/ropp/ropp_src/branches/dev/Share/<branch_name> |
| 46 | }}} |
| 47 | |
| 48 | '''Working in a branch''' |
| 49 | |
| 50 | Code developments are then made and logged within a branch as normal. |
| 51 | To view the local changes made to a branch, use the ''svn status'' command |
| 52 | |
| 53 | |
| 54 | '''Committing changes to a branch''' |
| 55 | |
| 56 | When changes to a branch are ready to be updated in the repository, the code needs to be committed. |
| 57 | {{{ |
| 58 | svn commit -m "Some text here to describe the changes" |
| 59 | }}} |
| 60 | This will prompt a list of the changes to be committed. |
| 61 | |
| 62 | When you are satisfied that all the changes you require to your branch have been committed and the ROPP Development Team are satisfied that it will be part of the next release, these changes will be merged back into the trunk by ROPP Admin. |
| 63 | |
| 64 | '''Keeping up to date with changes to trunk''' |
| 65 | |
| 66 | At some stage it may be necessary to update the trunk with latest developments while a user is still working in a particular branch. Users will be notified of any changes to trunk. |
| 67 | |
| 68 | In order to keep a branch up to date with the latest version of the trunk while you are working on your branch, you may want to bring in the changes that have been made to the main trunk. This can be done using the ''svn merge'' command. You must first change directory to your branch's working copy: e.g. |
| 69 | {{{ |
| 70 | cd ${HOME}/FCM/<branch name> |
| 71 | svn merge https://svn.grassaf.org/ropp/ropp_src/trunk |
| 72 | }}} |
| 73 | When you do this, you should see the list of updates that have been made to the trunk since you last brought in any changes (or since you branched). Note that this only results in changes to your working copy so you might want to commit them to the repository. |
| 74 | |
| 75 | It is useful to preview the files which will be changed on performing a merge before going ahead using: |
| 76 | {{{ |
| 77 | cd ${HOME}/FCM/<branch name> |
| 78 | svn merge --dry-run https://svn.grassaf.org/ropp/ropp_src/trunk |
| 79 | }}} |
| 80 | |
| 81 | Further information on branches are available in |
| 82 | [http://svnbook.red-bean.com/en/1.0/ch04.html#svn-ch-4-sect-1 SVN reference: Branching and Merging] |
| 83 | |
| 84 | [https://trac.grassaf.org/ropp/wiki/ropp_repository ropp_repository] |