diff options
| author | Junio C Hamano <gitster@pobox.com> | 2025-10-24 13:48:04 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2025-10-24 13:48:04 -0700 |
| commit | e7909b3a90ea75b2fffb89eba399c90c8669cc23 (patch) | |
| tree | 19a38a36f03930bab84cebaf2a07b338ffac92fa /wt-status.c | |
| parent | 385772e1834c394dede867dee05164a67b7b34f3 (diff) | |
| parent | 50927f4f683a35ad1c76c8a02a1759a076d3f8f8 (diff) | |
| download | git-e7909b3a90ea75b2fffb89eba399c90c8669cc23.tar.xz | |
Merge branch 'jk/status-z-short-fix'
The "--short" option of "git status" that meant output for humans
and "-z" option to show NUL delimited output format did not mix
well, and colored some but not all things. The command has been
updated to color all elements consistently in such a case.
* jk/status-z-short-fix:
status: make coloring of "-z --short" consistent
Diffstat (limited to 'wt-status.c')
| -rw-r--r-- | wt-status.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/wt-status.c b/wt-status.c index 8ffe6d3988..e12adb26b9 100644 --- a/wt-status.c +++ b/wt-status.c @@ -2042,13 +2042,13 @@ static void wt_shortstatus_status(struct string_list_item *it, static void wt_shortstatus_other(struct string_list_item *it, struct wt_status *s, const char *sign) { + color_fprintf(s->fp, color(WT_STATUS_UNTRACKED, s), "%s", sign); if (s->null_termination) { - fprintf(s->fp, "%s %s%c", sign, it->string, 0); + fprintf(s->fp, " %s%c", it->string, 0); } else { struct strbuf onebuf = STRBUF_INIT; const char *one; one = quote_path(it->string, s->prefix, &onebuf, QUOTE_PATH_QUOTE_SP); - color_fprintf(s->fp, color(WT_STATUS_UNTRACKED, s), "%s", sign); fprintf(s->fp, " %s\n", one); strbuf_release(&onebuf); } |
