Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to disable git pull.rebase (rebasing by default upon pull)

Tags:

git

I tried setting

git config --global pull.rebase false

and

git config pull.rebase false

and when I run

git config --global pull.rebase

or

git config pull.rebase

I see false, but when I run git pull ... it still is doing a rebase. How can I make this go away again?

like image 391
peter Avatar asked Dec 11 '22 13:12

peter


1 Answers

The best way

Don't use git pull. Just run git fetch and then when it's done, run git merge.

(This is also the best way to do rebase pulls: don't use git pull. "This ... is wrong tool. Never use this.")

The other way

Use git pull --rebase=false. The command line flag overrides the configuration setting.

like image 194
torek Avatar answered Mar 06 '23 19:03

torek