Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6899883
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T07:28:40+00:00 2026-05-27T07:28:40+00:00

I have not been able to find a similar answer to my question. Situation:

  • 0

I have not been able to find a similar answer to my question.

Situation:

Locally using GIT (git version 1.7.3.1.msysgit.0)
Remote repository is SVN (not sure of version)


Problem:

Clone an SVN repo, add a folder, commit it to git and SVN, rename the folder (without telling git), commit to git, cannot commit anymore to SVN.


Issue Steps
(SVN repo has one file in it main.as in the root folder)

  1. clone branch from SVN repo (now have one file locally)
  2. commit to git locally (including git add .)
  3. create oldFolder with a file in it
  4. commit to git locally (including git add .)
  5. dcommit to SVN
  6. rename oldFolder -> newFolder (rename with IDE or manually – not git-mv)
  7. commit to git locally (including git-add .)
  8. dcommit to SVN (don’t need SVN rebase since I’m the only one committing changes to SVN)

PROBLEM: The git-svn dcommit responds:

oldFolder/file.txt: needs update

update-index --refresh: command returned error: 1

What I tried:

  • stash, commit, dcommit, stash apply (same thing:needs update)
  • stash, rebase, stash apply, commit, dcommit (same thing:needs
    update)
  • stash, rebase, stash apply, commit, stash, dcommit
    (same thing:needs update)

The one that semi-worked was to call:

svn rm -r oldFolder

but this ended up with oldFolder and newFolder in SVN… whereas I want oldFolder to be either renamed or deleted (I don’t mind losing the history in this case).

I need the SVN repo to reflect my local git master/branch…


Why am I renaming files without the git command?
I work with large file structures and the IDEs that im using for refactoring old code renames multiple folders and files causing the above scenario. I cannot keep track and call git rm on every folder removed.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T07:28:40+00:00Added an answer on May 27, 2026 at 7:28 am

    At step 7, you staged the addition of the new file (newFolder/file.txt) but not the deletion of the old file. You’ll need to do the following instead of step 6 and 7 above:

    1. rename oldFolder -> newFolder (rename with IDE or manually – not git-mv)
    2. git add newFolder
    3. git rm -r oldFolder
    4. commit locally

    At this point, git will track renames (if any), and produce a correct commit for SVN.

    If your tree is still at step 7, you can do

    git reset --soft HEAD~
    

    to return to the previous commit and stage the deletion.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have not been able to find any definitive answers to this question: Can
My question is similar to this question . Though I have not been able
I have searched around and have not been able to find a solution for
I have a simple problem that I have not been able to find an
So this is something that I have not been able to find any documentation
Following the standard instruction for using AES algorithm, I have not been able to
I have been using this as a reference, but not able to accomplish exactly
I know similar questions have been asked but I have not been able to
I have another weird problem which I have not been able to solve in
I have no code to really display here, since I have not been able

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.