diff options
author | Junio C Hamano <gitster@pobox.com> | 2009-09-13 01:33:18 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-09-13 01:33:18 -0700 |
commit | dc1b0c06ee9b3d2fb086a89e5b12da35bf360e4c (patch) | |
tree | 4097a3e7f1507c66ef4effc9d2da243c6382a3ed /wt-status.c | |
parent | 8b54f63dce34c3bbd7ff919fb53c1c253221fe71 (diff) | |
parent | edf563fbaa2ab50734db4a61e9092f25fbb5a417 (diff) | |
download | git-dc1b0c06ee9b3d2fb086a89e5b12da35bf360e4c.tar.gz |
Merge branch 'jk/unwanted-advices'
* jk/unwanted-advices:
status: make "how to stage" messages optional
push: make non-fast-forward help message configurable
Diffstat (limited to 'wt-status.c')
-rw-r--r-- | wt-status.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/wt-status.c b/wt-status.c index 85f3fcb8a2..38eb24536b 100644 --- a/wt-status.c +++ b/wt-status.c @@ -48,6 +48,8 @@ static void wt_status_print_unmerged_header(struct wt_status *s) { const char *c = color(WT_STATUS_HEADER, s); color_fprintf_ln(s->fp, c, "# Unmerged paths:"); + if (!advice_status_hints) + return; if (!s->is_initial) color_fprintf_ln(s->fp, c, "# (use \"git reset %s <file>...\" to unstage)", s->reference); else @@ -60,6 +62,8 @@ static void wt_status_print_cached_header(struct wt_status *s) { const char *c = color(WT_STATUS_HEADER, s); color_fprintf_ln(s->fp, c, "# Changes to be committed:"); + if (!advice_status_hints) + return; if (!s->is_initial) { color_fprintf_ln(s->fp, c, "# (use \"git reset %s <file>...\" to unstage)", s->reference); } else { @@ -73,6 +77,8 @@ static void wt_status_print_dirty_header(struct wt_status *s, { const char *c = color(WT_STATUS_HEADER, s); color_fprintf_ln(s->fp, c, "# Changed but not updated:"); + if (!advice_status_hints) + return; if (!has_deleted) color_fprintf_ln(s->fp, c, "# (use \"git add <file>...\" to update what will be committed)"); else @@ -85,6 +91,8 @@ static void wt_status_print_untracked_header(struct wt_status *s) { const char *c = color(WT_STATUS_HEADER, s); color_fprintf_ln(s->fp, c, "# Untracked files:"); + if (!advice_status_hints) + return; color_fprintf_ln(s->fp, c, "# (use \"git add <file>...\" to include in what will be committed)"); color_fprintf_ln(s->fp, c, "#"); } |