merge

Git Stash

Currently, I am working on few files and when you do a git pull, you may sometimes get a message as follows:

error: Entry 'app/views/alerts/index.rhtml' not uptodate. Cannot merge.

So you know, somebody has updated the code and you do need to commit the file so that the file can be merged and for some reason I don’t want to commit till i finish the work. This is where git stash comes into play. from your root of the app, do the following command

pull with rebase

Users of Git are hopefully aware that a git pull does a git fetch to pull down data from the specified remote, and then calls git merge to join the changes received with your current branch’s work. However, that may not always be the best case. You can also rebase the changes in, and that may end up being a lot cleaner. This can be done simply by tacking on the --rebase option when you pull, like so:

Syndicate content