My contemplations and diurnal novelties are publicized here

Archive for December, 2015

Moving from SVN to Git with Branches and history

This article assume that you have familiar with SVN and Git both on a basic level.

  1. Install following component on your PC
    1. (Git Client like SVN)
  2. Create a repository similar to you root work folder like
    1. Source Code Git” for a repository like “Source Code
  3. Choose “Git Clone” option

  4. Provide your SVN url and local directory

  5. You will be prompted for you SVN repository password, enter you SVN repo password.
  6. Create a remote repository from your control panel like
    1. http://yourGITrepositoryUrl/yourproject.git
  7. Right Click on the local folder which you have created using SVN repository and select

  8. Type “Git Status” to check the status of your repository

  9. Also check the branches using following command
    1. Git branch -a
  10. Type $ “git remote add origin http://youGitRepositoryUrl” This will add a origin for your local repository where the changes will be pushed
  11. Type “git push –u origin master” to push trunk into the remote master branch. You will be prompted to enter username/password
  12. Now switch to other branches you want to push to the remote repository
  13. Type “git checkout yourbranchnamePresentinSVNRepository
  14. Once you branch is switched you can push it to the remote Git Repository by typing “git push –u origin yourBranchName“.
  15. Repeat the same for all your local branches until all are pushed to remote Git Repository.

To automatically save the Git UserName and Password (For Push and Pull)

  1. Goto git setting by right clicking on your project foldergit settings
  2. Select Advanced option and project url and username
  3. git settings panel
%d bloggers like this: