Featured post
Git svn work flow, making branchs in git-svn -
git version 1.7.3.3
i had project using git.
our company changed policy , wanted switch svn.
so imported project in subversion using standard layout (trunk, branchs, , tags).
so current workflow following:
make changes, put them in staging area, commit them git. however, little confused when comes svn. first rebase latest changes subversion. dcommit.
i.e.
stage change files
git stage app_driver.c
commit them git
git commit -m"added changes"
get latest changes svn
git svn rebase
commit latest changes svn
git svn dcommit
push changes git repository
git push upstream my_project
however, real confusion comes when make new branch in git, , how can commit branch in subversion.
git checkout -b add_new_feature
then how make new branch in svn , commit it?
many suggestions,
what create branch in subversion using svn copy.
for example, suppose trunk in https://svnserver/svn/myproject/trunk , want create branch in https://svnserver/svn/myproject/branches/my-branch, do:
svn copy https://svnserver/svn/myproject/trunk https://svnserver/svn/myproject/branches/my-branch
ok, rid of creating svn branch, fetch branch git go directory , git svn fetch. fetch things svn not modify current branches.
if started project git svn init --stdlayout branch appear when git branch -r. can checkout this:
git checkout -b my_local_branch_name my_remote_branch_name
note: not use same name local branch , remote branch or git complain (although works.)
then can work normal.
- Get link
- X
- Other Apps
Comments
Post a Comment