Re: [PATCH v16 09/10] imap-send: display the destination mailbox when sending a message
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jun 9, 2025, 18:57 UTC
- Message-ID
- <xmqq4iworbef.fsf@gitster.g>
- In-Reply-To
- <PN3PR01MB9597647A1FE9451BF9EB1C6DB86BA@PN3PR01MB9597.INDPRD01.PROD.OUTLOOK.COM>
Aditya Garg <gargaditya08@live.com> writes:
Show 17 quoted lines
> Whenever we sent a message using the `imap-send` command, it would > display a log showing the number of messages which are to be sent. > For example: > > sending 1 message > 100% (1/1) done > > This had been made more informative by adding the name of the destination > folder as well: > > Sending 1 message to Drafts folder... > 100% (1/1) done > > Signed-off-by: Aditya Garg <gargaditya08@live.com> > --- > imap-send.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-)
Hmph, I have to wonder how much value this adds. It is not like we extended imap-send to allow it to stuff messages to multiple imap folders during the same session (in which case, "sending ... to A" followed by "sending ... to B" may give a good feel of progress).
But that is minor, not an objection strong enough to shoot down a piece of code that has already been written. Capitalizing "Sending" certainly is a vast cosmetic improvement ;-).
Show 11 quoted lines
> diff --git a/imap-send.c b/imap-send.c > index 9807012169..3d6bcd7e88 100644 > --- a/imap-send.c > +++ b/imap-send.c > @@ -1563,7 +1563,8 @@ static int append_msgs_to_imap(struct imap_server_conf *server, > } > ctx->name = server->folder; > > - fprintf(stderr, "sending %d message%s\n", total, (total != 1) ? "s" : ""); > + fprintf(stderr, "Sending %d message%s to %s folder...\n", > + total, (total != 1) ? "s" : "", server->folder);
Totally outside the topic, but as #leftoverbits we may want to i18n/l10n the messages from this program after the dust settles from this series.