git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andy Whitcroft <apw@shadowen.org>
To: Juergen Ruehle <j.ruehle@bmiag.de>
Cc: git@vger.kernel.org, "Junio C Hamano" <junkio@cox.net>,
	"Jürgen Rühle" <j-r@online.de>
Subject: Re: [PATCH 2/4] Improve cached content header of status output
Date: Fri, 05 Jan 2007 10:54:15 +0000	[thread overview]
Message-ID: <459E2E57.6020503@shadowen.org> (raw)
In-Reply-To: <11677659921833-git-send-email-j.ruehle@bmiag.de>

Juergen Ruehle wrote:
> From: =?iso-8859-1?q?J=FCrgen_R=FChle?= <j-r@online.de>
> 
> This tries to be more to the point while also including a pointer on how to
> unstage changes from the index.
> 
> Since this header is printed in two different code paths and the name of the
> reference commit is needed for the unstage part, provide a new printing
> function.
> 
> Signed-off-by: Jürgen Rühle <j-r@online.de>
> ---
>  wt-status.c |   18 ++++++++++++++----
>  1 files changed, 14 insertions(+), 4 deletions(-)
> 
> diff --git a/wt-status.c b/wt-status.c
> index 34be91b..98ca135 100644
> --- a/wt-status.c
> +++ b/wt-status.c
> @@ -53,6 +53,18 @@ void wt_status_prepare(struct wt_status *s)
>  	s->untracked = 0;
>  }
>  
> +static void wt_status_print_cached_header(const char *reference)
> +{
> +	const char *c = color(WT_STATUS_HEADER);
> +	color_printf_ln(c, "# Cached changes to be committed:");
> +	if (reference) {
> +		color_printf_ln(c, "#   (use \"git reset %s <file>...\" and \"git rm --cached <file>...\" to unstage)", reference);
> +	} else {
> +		color_printf_ln(c, "#   (use \"git rm --cached <file>...\" to unstage)");
> +	}
> +	color_printf_ln(c, "#");

We seem to be using 'Cached' and 'staged' here.  I thought we had
updated all the docs to call files in the index "Staged for commit".  It
feels like the header should be more like:

     # Currently staged changes, will be commited:

The rm --cached is somewhat unfortunate either way.

-apw

  reply	other threads:[~2007-01-05 10:54 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-01-02 19:26 [PATCH/RFC] Assorted small changes to runstatus Juergen Ruehle
2007-01-02 19:26 ` [PATCH 1/4] Clarify syntax and role of git-add in status output Juergen Ruehle
2007-01-02 19:26 ` [PATCH 2/4] Improve cached content header of " Juergen Ruehle
2007-01-05 10:54   ` Andy Whitcroft [this message]
2007-01-05 11:22     ` Junio C Hamano
2007-01-05 13:14       ` Andy Whitcroft
2007-01-05 17:14         ` Juergen Ruehle
2007-01-05 18:42           ` Junio C Hamano
2007-01-08 13:28             ` Andy Whitcroft
2007-01-08 14:27               ` Juergen Ruehle
2007-01-02 19:26 ` [PATCH 3/4] Improve "nothing to commit" part " Juergen Ruehle
2007-01-02 19:26 ` [PATCH 4/4] Support --amend on initial commit in " Juergen Ruehle
2007-01-03  2:51 ` [PATCH/RFC] Assorted small changes to runstatus Junio C Hamano
2007-01-03  5:34   ` Juergen Ruehle
2007-01-07 19:18 ` [PATCH] Remove unnecessary git-rm --cached reference from status output Juergen Ruehle

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=459E2E57.6020503@shadowen.org \
    --to=apw@shadowen.org \
    --cc=git@vger.kernel.org \
    --cc=j-r@online.de \
    --cc=j.ruehle@bmiag.de \
    --cc=junkio@cox.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).