Changes between Version 24 and Version 25 of DRM4G/Development

Feb 20, 2017 7:37:00 PM (5 years ago)



  • DRM4G/Development

    v24 v25  
     473= SVN repository migration to Git =
     475This section exists in case there's a need to convert any other project from '''''Subversion''''' to '''''Git''''', including ''tags'', the same way that has been done for the ''DRM4G'' and ''WRF4G''. There may be better ways of doing it, but this is the only one that we've tested.
     477The program used is called [ svn2git]. Follow the link to see how to install it.
     479Once installed, you can try to use the options they have listed in [ usage].
     481* First create a new folder where you want to have your local repository and change into it
     484mkdir <local_repository_folder>
     485cd <local_repository_folder>
     488* This next command will then '''__convert the whole remote svn repository__''' into a local git repository.
     489 * You'll need the `--username` option since our repository is protected by password.
     490 * This process will take a long time.
     493svn2git --username <user_name>
     496* When it's done, get into the branch you want to start a project from and rename it as the ''__master__''
     497 * You might have to clean up a bit the root folder, since there might be some folders that shouldn't be there. But they should be empty and should be fine to just delete them.
     500git checkout <project_branch>
     501rm -rf WRF* #if you need to clean up
     502#if they were empty you won't need to make a commit
     504#rename the project branch
     505git branch -m master old-master
     506git branch -m <project_branch> master
     509* Then push it to our remote repository in '''''!GitHub'''''
     512git remote add origin<project_name>.git
     513git push -u origin master
     516* Finally, depending on whether you'll need the rest or not, delete the remaining branches.
     519git branch
     520git branch -D <every_branch>