Jeff Storey Jeff Storey - 1 year ago 169
Git Question

git rebase after pull

I typically use

git pull --rebase
if I'm working directly on master (which I try not to do anyway). In the event that I forgot to do a rebase and just did
git pull
, is there a way to undo that and make it linear, rather than having a merge? Would doing a rebase at this point be a bad idea (if that would even accomplish anything)?

I know I can put enable rebasing on pulls by default so I don't forget, but this is more of an issue of understanding what to do in this case.

Answer Source

i guess git reset --hard back to before the pull and redo the pull is the way

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download