diff options
author | Junio C Hamano <gitster@pobox.com> | 2021-05-11 15:27:22 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-05-11 15:27:22 +0900 |
commit | 5feebddd8683f40bc53de0f6ea0883fc13042dc3 (patch) | |
tree | 05c26b12b3eaa517ae046bdcf460519264623722 | |
parent | Merge branch 'rj/bisect-skip-honor-terms' (diff) | |
parent | merge: fix swapped "up to date" message components (diff) | |
download | tgif-5feebddd8683f40bc53de0f6ea0883fc13042dc3.tar.xz |
Merge branch 'js/merge-already-up-to-date-message-reword'
A few variants of informational message "Already up-to-date" has
been rephrased.
* js/merge-already-up-to-date-message-reword:
merge: fix swapped "up to date" message components
merge(s): apply consistent punctuation to "up to date" messages
-rw-r--r-- | builtin/merge.c | 14 | ||||
-rw-r--r-- | merge-ort-wrappers.c | 2 | ||||
-rw-r--r-- | merge-recursive.c | 2 | ||||
-rw-r--r-- | notes-merge.c | 2 |
4 files changed, 12 insertions, 8 deletions
diff --git a/builtin/merge.c b/builtin/merge.c index 388619536a..eddb8ae70d 100644 --- a/builtin/merge.c +++ b/builtin/merge.c @@ -393,10 +393,14 @@ static void restore_state(const struct object_id *head, } /* This is called when no merge was necessary. */ -static void finish_up_to_date(const char *msg) +static void finish_up_to_date(void) { - if (verbosity >= 0) - printf("%s%s\n", squash ? _(" (nothing to squash)") : "", msg); + if (verbosity >= 0) { + if (squash) + puts(_("Already up to date. (nothing to squash)")); + else + puts(_("Already up to date.")); + } remove_merge_branch_state(the_repository); } @@ -1522,7 +1526,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix) * If head can reach all the merge then we are up to date. * but first the most common case of merging one remote. */ - finish_up_to_date(_("Already up to date.")); + finish_up_to_date(); goto done; } else if (fast_forward != FF_NO && !remoteheads->next && !common->next && @@ -1610,7 +1614,7 @@ int cmd_merge(int argc, const char **argv, const char *prefix) } } if (up_to_date) { - finish_up_to_date(_("Already up to date. Yeeah!")); + finish_up_to_date(); goto done; } } diff --git a/merge-ort-wrappers.c b/merge-ort-wrappers.c index 7eec25f93a..ad04106169 100644 --- a/merge-ort-wrappers.c +++ b/merge-ort-wrappers.c @@ -30,7 +30,7 @@ int merge_ort_nonrecursive(struct merge_options *opt, return -1; if (oideq(&merge_base->object.oid, &merge->object.oid)) { - printf(_("Already up to date!")); + printf_ln(_("Already up to date.")); return 1; } diff --git a/merge-recursive.c b/merge-recursive.c index b7696f3946..d146bb116f 100644 --- a/merge-recursive.c +++ b/merge-recursive.c @@ -3462,7 +3462,7 @@ static int merge_trees_internal(struct merge_options *opt, } if (oideq(&merge_base->object.oid, &merge->object.oid)) { - output(opt, 0, _("Already up to date!")); + output(opt, 0, _("Already up to date.")); *result = head; return 1; } diff --git a/notes-merge.c b/notes-merge.c index 53c587f750..12e8472b65 100644 --- a/notes-merge.c +++ b/notes-merge.c @@ -628,7 +628,7 @@ int notes_merge(struct notes_merge_options *o, if (oideq(&remote->object.oid, base_oid)) { /* Already merged; result == local commit */ if (o->verbosity >= 2) - printf("Already up to date!\n"); + printf_ln("Already up to date."); oidcpy(result_oid, &local->object.oid); goto found_result; } |