git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Git Pull --ff-only should imply --no-rebase

From
SCShane Carr <sffc@google.com>
Date
Feb 25, 2019, 08:42 UTC
Message-ID
<CABxsp=msDSGGFjn178ze-s3XR3UJU=NEkV1jzS9QN-zjZisMgg@mail.gmail.com>
Greetings,

I have the pull.rebase config enabled for my branch. Sometimes I want to pull and I know that the pull is going to be a fast-forward. However, if I run

    git pull --ff-only   # (with pull.rebase config enabled)
I get the error
    error: Cannot pull with rebase: You have unstaged changes.
Instead, if my working directory is not clean, I have to do
    git pull --ff-only --no-rebase

Since --ff-only implies that there is going to be neither a merge nor a rebase taking place, Git should not complain about unstaged changes and should have the same behavior on --ff-only whether or not the pull.rebase config is enabled.

Shane
Message 1 of 1 in “Git Pull --ff-only should imply --no-rebase”
  1. Shane CarrFeb 25, 2019

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.