diff options
author | Jeff King <peff@peff.net> | 2012-05-07 17:09:04 -0400 |
---|---|---|
committer | Jeff King <peff@peff.net> | 2012-05-08 04:51:08 -0400 |
commit | d4a6bf1fb64d904e210fbf7c5b330b06438a5bd5 (patch) | |
tree | e730861e04c858757025a81f93df92d3f10e8729 /wt-status.h | |
parent | a5985237878481af5fbca349d0d1ad7d6b2d2bcb (diff) | |
download | git-d4a6bf1fb64d904e210fbf7c5b330b06438a5bd5.tar.gz git-d4a6bf1fb64d904e210fbf7c5b330b06438a5bd5.tar.xz |
status: respect "-b" for porcelain format
There is no reason not to, as the user has to explicitly ask
for it, so we are not breaking compatibility by doing so. We
can do this simply by moving the "show_branch" flag into
the wt_status struct. As a bonus, this saves us from passing
it explicitly, simplifying the code.
Signed-off-by: Jeff King <peff@peff.net>
Diffstat (limited to 'wt-status.h')
-rw-r--r-- | wt-status.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/wt-status.h b/wt-status.h index 34a8d7614..ab3c7cc8a 100644 --- a/wt-status.h +++ b/wt-status.h @@ -57,6 +57,7 @@ struct wt_status { const char *ignore_submodule_arg; char color_palette[WT_STATUS_MAXSLOT][COLOR_MAXLEN]; int null_termination; + int show_branch; /* These are computed during processing of the individual sections */ int commitable; @@ -73,7 +74,7 @@ void wt_status_prepare(struct wt_status *s); void wt_status_print(struct wt_status *s); void wt_status_collect(struct wt_status *s); -void wt_shortstatus_print(struct wt_status *s, int show_branch); +void wt_shortstatus_print(struct wt_status *s); void wt_porcelain_print(struct wt_status *s); void status_printf_ln(struct wt_status *s, const char *color, const char *fmt, ...) |