From: Felipe Contreras <felipe.contreras@gmail.com>
To: Matthias Baumgarten <matthias.baumgarten@aixigo.com>,
"git@vger.kernel.org" <git@vger.kernel.org>
Subject: RE: pull.rebase config vs. --ff-only on command line
Date: Fri, 16 Jul 2021 11:39:08 -0500 [thread overview]
Message-ID: <60f1b62c7531c_ade9208d8@natae.notmuch> (raw)
In-Reply-To: <c62933fb-96b2-99f5-7169-372f486f6e39@aixigo.com>
Hello Matthias,
Matthias Baumgarten wrote:
> this is my first time contacting you guys and girls so I hope this mail
> achieves the expected standard. I've discovered the following behaviour
> of git:
>
> If pull.rebase is configured to true and git pull --ff-only is executed
> it seems like the config wins, i.e. issuing "Successfully rebased and
> updated refs/heads/...", which is not what I would expect. I always
> believed that command line options would overwrite configured options.
>
> Is my assumption that command line options always win wrong or is this a
> bug?
Yes, your assumption is correct, but the equivalent of that combination
is:
git pull --rebase --ff-only
But --ff-only is only meant for the merge mode of `git pull`
(git pull --merge), not the rebase mode, so it's ignored. You can see
that from the documentation [1]:
With --ff-only, resolve the merge as a fast-forward when possible.
When not possible, refuse to merge and exit with a non-zero status.
Note the *merge* part.
[1] https://git-scm.com/docs/git-pull
--
Felipe Contreras
prev parent reply other threads:[~2021-07-16 16:39 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-16 14:43 pull.rebase config vs. --ff-only on command line Matthias Baumgarten
2021-07-16 15:03 ` Elijah Newren
2021-07-16 16:44 ` Felipe Contreras
2021-07-16 16:54 ` Matthias Baumgarten
2021-07-16 18:00 ` Felipe Contreras
2021-07-19 14:26 ` Matthias Baumgarten
2021-07-19 17:43 ` Felipe Contreras
2021-07-22 18:57 ` Junio C Hamano
2021-07-22 22:09 ` Felipe Contreras
2021-07-23 9:36 ` Matthias Baumgarten
2021-07-16 16:39 ` Felipe Contreras [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=60f1b62c7531c_ade9208d8@natae.notmuch \
--to=felipe.contreras@gmail.com \
--cc=git@vger.kernel.org \
--cc=matthias.baumgarten@aixigo.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.