SUPPORT THE SITE WITH A CLICK

Subscribe Rss:

SUPPORT THE SITE WITH A CLICK

Friday, December 17, 2010

error: Entry foo not uptodate. Cannot merge

I have forked one of my friends repository to work along with him.While i was updating the recent changes from my friends repo using

git fetch coreteam


Later on pushing the code to my own repo, i stuck with this error.
Updating b5f53fc..56d17b7
error: Entry 'db/schema.rb' not uptodate. Cannot merge.


Later stumbling in net i found the solution, then i did the following steps

1.git stash

git stash when you want to record the current state of the working directory and the index, but want to go back to a clean working directory. The command saves your local modifications away and reverts the working directory to match the HEAD commit.

2.git pull

& finally

3.git merge coreteam/master
to merge my friends code to my own repo.