Version 14 (modified by nicolasmartin, 8 years ago) (diff) |
---|
-
Working with SVN and tickets
- How to get permissions
- How to create a new routine
- How to make a branch
- How to make a commit
- How to make a tag
- How to make a merge
- How to make an update of a given file between 2 different branches e.g …
- How to get information about the sources downloaded
- Switch from user to developer
- Switch from a branch to the trunk (your working copy was based on a given …
- How to create a ticket wiki page
Working with SVN and tickets
Last edited Timestamp?
How to get permissions
Send a request once for all to Nicolas with the list of your nemo website user names
How to create a new routine
Use the template source:trunk/NEMOGCM/NEMO/OPA_SRC/module_example
If not don't forget to set the SVN property of the routine in order to get the functionality of SVN Id keyword replacement
svn propset svn:keywords Id New_routine.f90
How to make a branch
For branch naming conventions, see https://forge.ipsl.jussieu.fr/nemo/wiki/Developers/WorkingPractices#CreateaBranch
svn copy svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/branches/dev_r1720_SBC -m "Create a specific branch for the New Surface Module"
For development branches, we tend to add one level of subdirectory corresponding to the current year, and an additional item in the name corresponding to the work-plan,for instance:
svn copy svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/branches/2011/dev_r1720_LOCEAN1_mpp -m "Create a specific branch for mpp evolution"
How to make a commit
Extract with svn+http protocol
svn co svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/branches/dev_001_SBC
Then in the appropriate directory : export SVN_EDITOR=vi (ksh, bash, to put in .profile or .bash_profile) or setenv SVN_EDITOR vi (tsch, to put in .login)
svn ci -m [ "#ticket_number : bla bla ... ] [ files list ]
How to make a tag
svn copy svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/tags/nemo_v2_3 -m "Tagging nemo_v2_3"
How to make a merge
To get all changes from the revision 746 to the current one (HEAD) on a specific directory
cd ./NEMO/OPA_SRC/IOM (you already downloaded the branche you are working on) svn merge -r 746:HEAD svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk/NEMO/OPA_SRC/IOM -m "Merge my local IOM directory with the trunk repository "
How to make an update of a given file between 2 different branches e.g trunk and tags directories
Suppose the downloaded NEMO directory corresponds to the tag nemo_v3 (i.e. from http://forge.ipsl.jussieu.fr/nemo/svn/tags/nemo_v3/NEMO); the current revision number of the file sbcssm.F90 is 1196. To get the new revision (which has been committed on the trunk http://forge.ipsl.jussieu.fr/nemo/svn/trunk/NEMO ) with the revision number 1214:
cd ./modeles/NEMO/OPA_SRC/SBC/ svn merge -r 1196:1214 http://forge.ipsl.jussieu.fr/nemo/svn/trunk/NEMO/OPA_SRC/SBC/sbcssm.F90
How to get information about the sources downloaded
To get information such as the PATH/URL you are working on, .i.e. trunk, branches .. and so on
cd ./NEMO svn info
To get all commits/revision performed/associated on/to your working repository since its creation
cd ./NEMO svn log --verbose --stop-on-copy
Switch from user to developer
svn switch --relocate http://forge.ipsl.jussieu.fr/nemo/svn/trunk/NEMO svn+ssh://yourloginforge@forge.ipsl.jussieu.fr/ipsl/forge/projets/nemo/svn/trunk/NEMO
Switch from a branch to the trunk (your working copy was based on a given branch which has been moved to the trunk
svn switch http://forge.ipsl.jussieu.fr/nemo/svn/trunk/NEMOGCM
Comments: takes some time and asks if conflicts
How to create a ticket wiki page
In your browser, open https://forge.ipsl.jussieu.fr/nemo/wiki/ticket/xxxx with xxxx the ticket number and choose NEMOTicketTemplate or in your ticket add the markup wiki:ticket/xxxx? and follow the link