Git-svn rebase and dcommit problem

git version 1.7.1 svn, version 1.6.12 Ubuntu 10.10 

I only have git and I used svn. But I did not use them together. I had a git repository and I had more of my repository for disruptive. So I used git-svn. Which works fine, most of the time. However, I find circles in circles.

I am the only one working on this project.

I am making some changes to my thread. Then I put them:

 git stage gateway.c 

Then copy them locally to git:

 git commit m"Made some changes" 

Then I want to convey their subversive activities. Get the latest updates:

 git svn rebase 

Then I get the following message:

 It seems that I cannot create a rebase-apply directory, and I wonder if you are in the middle of patch application or another rebase. If that is not the case, please rm -fr /home/joe/projects/gateway/.git/rebase-apply and run me again. I am stopping in case you still have something valuable there. rebase refs/remotes/trunk: command returned error: 1 I then doing the following: rm -fr /home/joe/projects/gateway/.git/rebase-apply 

Then I do the reconfiguration again:

 git svn rebase 

The message is as follows:

 First, rewinding head to replay your work on top of it... Applying: Issue with getting the port from the user context. Using index info to reconstruct a base tree... Falling back to patching base and 3-way merge... Auto-merging driver.c Auto-merging gateway.c CONFLICT (content): Merge conflict in gateway.c Failed to merge in the changes. Patch failed at 0001 Issue with getting the port from the user context. When you have resolved this problem run "git rebase --continue". If you would prefer to skip this patch, instead run "git rebase --skip". To restore the original branch and stop rebasing run "git rebase --abort". rebase refs/remotes/trunk: command returned error: 1 

What puts me on a branch, and what is this branch and what is it for ?:

 *(no branch) 

Then I resolve conflicts with this branch. Then I check my play_video branch. I am trying to do another:

 svn git dcommit 

And I circle again.

Before I start pulling my hair, can someone offer me advice,

Thanks so much for any suggestions,

+8
git svn git-svn
source share
3 answers

There is no complete answer, but it seems to be like this:

 *(no branch) 

means you got into the DETACHED HEAD mode that you see in the git svn context in Can I recover lost commits in the SVN repository using local tracking git-svn branch? "
See also " Why did git disconnect my head? ".

Therefore, make sure that:

  • at each step you are not in a separate head (without a branch)
  • that you dcommit branch that exists in your SVN registry (and not in the local local git branch)
+3
source share

Did you use the google instructions here to import the git repository into svn? I had a similar error after using these instructions: the initial import went fine, but something went wrong and I could not push the subsequent commits.

I let it just git svn init in the new git repository to track my svn repository.

+1
source share

After resolving conflicts, you need to run git rebase --continue before running git svn dcommit

+1
source share

Source: https://habr.com/ru/post/650116/


All Articles