From: "Phillip Wood via GitGitGadget" <gitgitgadget@gmail.com>
To: git@vger.kernel.org
Cc: Elijah Newren <newren@gmail.com>,
Phillip Wood <phillip.wood123@gmail.com>,
Phillip Wood <phillip.wood@dunelm.org.uk>
Subject: [PATCH v2 0/5] merge-tree --stdin: flush stdout
Date: Tue, 18 Feb 2025 16:24:34 +0000 [thread overview]
Message-ID: <pull.1862.v2.git.1739895879.gitgitgadget@gmail.com> (raw)
In-Reply-To: <pull.1862.git.1739723829.gitgitgadget@gmail.com>
Thanks to Elijah for his comments on V1. I've updated the commit message of
patch 2 as he suggested. The rest of the patches are unchanged.
V1 Cover Letter:
I tried to squash some fixup commits with "git merge-tree --stdin" and found
that my script deadlocked because the output of "git merge-tree" is not
flushed after each merge. The first patch fixes that and the rest are
cleanups I noticed while reading the code and documentation. This series is
based on maint.
Phillip Wood (5):
merge-tree --stdin: flush stdout to avoid deadlock
merge-tree: remove redundant code
merge-tree: only use basic merge config
merge-tree: improve docs for --stdin
merge-tree: fix link formatting in html docs
Documentation/git-merge-tree.txt | 11 ++++++++---
builtin/merge-tree.c | 11 +++++------
2 files changed, 13 insertions(+), 9 deletions(-)
base-commit: f93ff170b93a1782659637824b25923245ac9dd1
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-1862%2Fphillipwood%2Fmerge-tree-flush-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-1862/phillipwood/merge-tree-flush-v2
Pull-Request: https://github.com/gitgitgadget/git/pull/1862
Range-diff vs v1:
1: 3b317978509 = 1: 3b317978509 merge-tree --stdin: flush stdout to avoid deadlock
2: 16fec87766f ! 2: 63b09dbe1b7 merge-tree: remove redundant code
@@ Commit message
real_merge() only ever returns "0" or "1" as it dies if the merge status
is less than zero. Therefore the check for "result < 0" is redundant and
- the result variable is not needed.
+ the result variable is not needed. The return value of real_merge() is
+ ignored because exit status of "git merge-tree --stdin" is "0" for both
+ successful and conflicted merges (the status of each merge is written to
+ stdout). The return type of real_merge() is not changed as it is used
+ for the program's exit status when "--stdin" is not given.
Signed-off-by: Phillip Wood <phillip.wood@dunelm.org.uk>
3: bf1dc603a15 = 3: f95a15a4203 merge-tree: only use basic merge config
4: 4c416850634 = 4: 1645b0e747e merge-tree: improve docs for --stdin
5: 89722894c87 = 5: a0179820092 merge-tree: fix link formatting in html docs
--
gitgitgadget
next prev parent reply other threads:[~2025-02-18 16:24 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-16 16:37 [PATCH 0/5] merge-tree --stdin: flush stdout Phillip Wood via GitGitGadget
2025-02-16 16:37 ` [PATCH 1/5] merge-tree --stdin: flush stdout to avoid deadlock Phillip Wood via GitGitGadget
2025-02-17 20:01 ` Elijah Newren
2025-02-16 16:37 ` [PATCH 2/5] merge-tree: remove redundant code Phillip Wood via GitGitGadget
2025-02-17 20:15 ` Elijah Newren
2025-02-18 10:01 ` Phillip Wood
2025-02-16 16:37 ` [PATCH 3/5] merge-tree: only use basic merge config Phillip Wood via GitGitGadget
2025-02-16 16:37 ` [PATCH 4/5] merge-tree: improve docs for --stdin Phillip Wood via GitGitGadget
2025-02-17 20:26 ` Elijah Newren
2025-02-18 10:02 ` Phillip Wood
2025-02-18 15:56 ` Elijah Newren
2025-02-16 16:37 ` [PATCH 5/5] merge-tree: fix link formatting in html docs Phillip Wood via GitGitGadget
2025-02-17 20:30 ` Elijah Newren
2025-02-18 16:24 ` Phillip Wood via GitGitGadget [this message]
2025-02-18 16:24 ` [PATCH v2 1/5] merge-tree --stdin: flush stdout to avoid deadlock Phillip Wood via GitGitGadget
2025-02-19 6:23 ` Patrick Steinhardt
2025-02-19 14:55 ` Phillip Wood
2025-02-19 16:02 ` Junio C Hamano
2025-02-18 16:24 ` [PATCH v2 2/5] merge-tree: remove redundant code Phillip Wood via GitGitGadget
2025-02-18 16:24 ` [PATCH v2 3/5] merge-tree: only use basic merge config Phillip Wood via GitGitGadget
2025-02-18 16:24 ` [PATCH v2 4/5] merge-tree: improve docs for --stdin Phillip Wood via GitGitGadget
2025-02-18 16:24 ` [PATCH v2 5/5] merge-tree: fix link formatting in html docs Phillip Wood via GitGitGadget
2025-02-18 16:46 ` [PATCH v2 0/5] merge-tree --stdin: flush stdout Elijah Newren
2025-02-18 16:54 ` Phillip Wood
2025-02-18 19:35 ` Junio C Hamano
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=pull.1862.v2.git.1739895879.gitgitgadget@gmail.com \
--to=gitgitgadget@gmail.com \
--cc=git@vger.kernel.org \
--cc=newren@gmail.com \
--cc=phillip.wood123@gmail.com \
--cc=phillip.wood@dunelm.org.uk \
/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.