Re: [PATCH] push: improve consistency of output when "up to date"
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- Jan 12, 2024, 03:14 UTC
- Message-ID
- <CAPig+cSO74EbK7RS5t3TAbRLUuLyynenugg4RgsOQ_=VyA4aAw@mail.gmail.com>
- In-Reply-To
- <xmqqjzofec0e.fsf@gitster.g>
On Thu, Jan 11, 2024 at 5:33 PM Junio C Hamano <gitster@pobox.com> wrote:
Show 17 quoted lines
> Eric Sunshine <sunshine@sunshineco.com> writes: > > Thanks. This particular change is proposed periodically... > > ... but has not been considered desirable. > > > > See, for instance, this email thread explaining the rationale for > > avoiding such a change: > > https://lore.kernel.org/git/pull.1298.git.1658908927714.gitgitgadget@gmail.com/T/ > > Let's do the second best thing, leave a short comment near them, to > make it possible for those who are motivated enough to find out why > we decided to tell them "do not modify". > --- > diff --git a/builtin/send-pack.c b/builtin/send-pack.c > @@ -333,6 +333,7 @@ int cmd_send_pack(int argc, const char **argv, const char *prefix) > if (!ret && !transport_refs_pushed(remote_refs)) > + /* do not modify this string */ > fprintf(stderr, "Everything up-to-date\n");
Yes, that helps, though, we can probably be a bit more friendly to future developers. Rather than insisting that they dig through history, we could use a slightly less terse comment, such as:
/* stable plumbing output; do not modify or localize */