update: explicitly no-ff merge and rebase.
This overrides user configuration which may do otherwise. Closes Homebrew/homebrew#41570. Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
This commit is contained in:
parent
8d2e757253
commit
f431e543a5
@ -196,7 +196,8 @@ class Updater
|
||||
safe_system "git", "config", "core.autocrlf", "false"
|
||||
|
||||
args = ["pull"]
|
||||
args << "--rebase" if ARGV.include? "--rebase"
|
||||
args << "--ff"
|
||||
args << ((ARGV.include? "--rebase") ? "--rebase" : "--no-rebase")
|
||||
args += quiet
|
||||
args << "origin"
|
||||
# the refspec ensures that 'origin/master' gets updated
|
||||
|
@ -61,7 +61,7 @@ class UpdaterTests < Homebrew::TestCase
|
||||
@updater.in_repo_expect("git symbolic-ref --short HEAD", "master")
|
||||
@updater.in_repo_expect("git rev-parse -q --verify HEAD", "1234abcd")
|
||||
@updater.in_repo_expect("git config core.autocrlf false")
|
||||
@updater.in_repo_expect("git pull --quiet origin refs/heads/master:refs/remotes/origin/master")
|
||||
@updater.in_repo_expect("git pull --ff --no-rebase --quiet origin refs/heads/master:refs/remotes/origin/master")
|
||||
@updater.in_repo_expect("git rev-parse -q --verify HEAD", "3456cdef")
|
||||
@updater.pull!(:silent => true)
|
||||
@updater.in_repo_expect("git rev-parse -q --verify HEAD", "3456cdef")
|
||||
|
Loading…
x
Reference in New Issue
Block a user