git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Jeff King <peff@peff.net>
To: Kaartic Sivaraam <kaarticsivaraam91196@gmail.com>
Cc: Samuel Lijin <sxlijin@gmail.com>,
	Junio C Hamano <gitster@pobox.com>,
	"git@vger.kernel.org" <git@vger.kernel.org>,
	"brian m. carlson" <sandals@crustytoothpaste.net>
Subject: Re: [PATCH] wt-status.c: Modified status message shown for a parent-less branch
Date: Fri, 16 Jun 2017 06:50:32 -0400	[thread overview]
Message-ID: <20170616105032.rjmmql56ifol34mk@sigill.intra.peff.net> (raw)
In-Reply-To: <1497609408.2517.4.camel@gmail.com>

On Fri, Jun 16, 2017 at 04:06:48PM +0530, Kaartic Sivaraam wrote:

> From what I could get from this thread, I guess the current patch
> stands something like the one below. I tried building it with the below
> change, it seems to be having a little issue. I'm not sure why, it
> seems to be working the other way round i.e., the message "No commits
> yet on the branch" message is shown in the commit template and the
> message "Initial commit" is shown when `git status` is invoked.
> 
> Also, let me know if any other change is required.
> 
> diff --git a/builtin/commit.c b/builtin/commit.c
> index 1d805f5da..3ed8e40bc 100644
> --- a/builtin/commit.c
> +++ b/builtin/commit.c
> @@ -1364,6 +1364,7 @@ int cmd_status(int argc, const char **argv, const
> char *prefix)
>                 usage_with_options(builtin_status_usage,
> builtin_status_options);
>  
>         status_init_config(&s, git_status_config);
> +       s.commit_template = 1;
>         argc = parse_options(argc, argv, prefix,
>                              builtin_status_options,
>                              builtin_status_usage, 0);

Wouldn't you want this in cmd_commit(), not cmd_status()?

-Peff

  reply	other threads:[~2017-06-16 10:50 UTC|newest]

Thread overview: 48+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-06-10  1:52 [PATCH] wt-status.c: Modified status message shown for a parent-less branch Kaartic Sivaraam
2017-06-10  2:10 ` Kaartic Sivaraam
2017-06-10  2:23 ` Junio C Hamano
2017-06-10  8:44   ` Kaartic Sivaraam
2017-06-10  9:36     ` Kaartic Sivaraam
2017-06-10 10:21     ` Jeff King
2017-06-10 11:02       ` Junio C Hamano
2017-06-12  8:10         ` Kaartic Sivaraam
2017-06-12 18:28           ` Junio C Hamano
2017-06-12 21:20             ` Jeff King
2017-06-12 21:31               ` Junio C Hamano
2017-06-12 21:37                 ` Jeff King
2017-06-15  8:19                   ` Kaartic Sivaraam
2017-06-15  8:42                     ` Jeff King
2017-06-15 11:43                       ` Samuel Lijin
2017-06-15 13:12                         ` Jeff King
2017-06-16 10:36                           ` Kaartic Sivaraam
2017-06-16 10:50                             ` Jeff King [this message]
2017-06-18  7:35                               ` [PATCH/Almost final] " Kaartic Sivaraam
2017-06-18  7:53                                 ` [PATCH/ALMOST FINAL] Contextually notify user about an initial commit Kaartic Sivaraam
2017-06-18  8:34                                   ` Ævar Arnfjörð Bjarmason
2017-06-19  2:41                                     ` [PATCH 1/2] " Kaartic Sivaraam
2017-06-19  2:44                                       ` [PATCH 2/2] Add test for the new status message Kaartic Sivaraam
2017-06-19  4:32                                         ` Junio C Hamano
2017-06-19 17:59                                           ` Kaartic Sivaraam
2017-06-19 18:04                                             ` Jeff King
2017-06-19 18:33                                               ` Kaartic Sivaraam
2017-06-19  4:29                                       ` [PATCH 1/2] Contextually notify user about an initial commit Junio C Hamano
2017-06-19  2:41                                     ` [PATCH 2/2] Add test for the new status message Kaartic Sivaraam
2017-06-19  9:10                                     ` [PATCH/ALMOST FINAL] Contextually notify user about an initial commit Jeff King
2017-06-19 13:24                                       ` Kaartic Sivaraam
2017-06-19 15:47                                       ` Junio C Hamano
2017-06-20  3:02                                         ` [PATCH 1/3] " Kaartic Sivaraam
2017-06-20  3:02                                           ` [PATCH 2/3] Update test(s) that used old status message Kaartic Sivaraam
2017-06-20  3:02                                           ` [PATCH 3/3] Add tests for the contextual initial " Kaartic Sivaraam
2017-06-20  7:26                                           ` [PATCH 1/3] Contextually notify user about an initial commit Ævar Arnfjörð Bjarmason
2017-06-20 13:37                                             ` Kaartic Sivaraam
2017-06-20 14:41                                               ` Ævar Arnfjörð Bjarmason
2017-06-21  2:34                                                 ` Kaartic Sivaraam
2017-06-21  2:37                                                   ` [PATCH/FINAL] status: contextually " Kaartic Sivaraam
2017-06-21 14:35                                                     ` Kaartic Sivaraam
2017-06-21 14:52                                                       ` Ævar Arnfjörð Bjarmason
2017-06-21 17:45                                                         ` Kaartic Sivaraam
2017-06-21 18:45                                                           ` Junio C Hamano
2017-06-21 18:16                                                         ` Kaartic Sivaraam
2017-06-22  2:10                                                           ` Junio C Hamano
2017-06-22  3:01                                                             ` Kaartic Sivaraam
2017-06-10 14:44     ` [PATCH] wt-status.c: Modified status message shown for a parent-less branch Philip Oakley

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

  List information: http://vger.kernel.org/majordomo-info.html

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

  git send-email \
    --in-reply-to=20170616105032.rjmmql56ifol34mk@sigill.intra.peff.net \
    --to=peff@peff.net \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=kaarticsivaraam91196@gmail.com \
    --cc=sandals@crustytoothpaste.net \
    --cc=sxlijin@gmail.com \
    /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.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

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 read-only IMAP folder(s) and NNTP newsgroup(s).