summaryrefslogtreecommitdiff
path: root/wt-status.h
diff options
context:
space:
mode:
authorJeff King <peff@peff.net>2012-05-07 17:09:04 -0400
committerJeff King <peff@peff.net>2012-05-08 04:51:08 -0400
commitd4a6bf1fb64d904e210fbf7c5b330b06438a5bd5 (patch)
treee730861e04c858757025a81f93df92d3f10e8729 /wt-status.h
parenta5985237878481af5fbca349d0d1ad7d6b2d2bcb (diff)
downloadgit-d4a6bf1fb64d904e210fbf7c5b330b06438a5bd5.tar.gz
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.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/wt-status.h b/wt-status.h
index 34a8d7614f..ab3c7cc8a1 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, ...)