user/dev discussion of public-inbox itself
 help / color / mirror / code / Atom feed
From: Eric Wong <e@80x24.org>
To: meta@public-inbox.org
Subject: [PATCH 3/3] watch: add space before "UID" or "ARTICLE" in warnings
Date: Mon, 13 Mar 2023 19:38:27 +0000	[thread overview]
Message-ID: <20230313193827.3635690-4-e@80x24.org> (raw)
In-Reply-To: <20230313193827.3635690-1-e@80x24.org>

In other words, it now shows `imap://example.com/INBOX.foo UID:123'
instead of: `imap://example.com/INBOX.foo UID:123'
---
 lib/PublicInbox/Watch.pm | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/PublicInbox/Watch.pm b/lib/PublicInbox/Watch.pm
index 90d82d21..d9aadf82 100644
--- a/lib/PublicInbox/Watch.pm
+++ b/lib/PublicInbox/Watch.pm
@@ -312,7 +312,7 @@ sub imap_fetch_all ($$) {
 	local $SIG{__WARN__} = sub {
 		my $pfx = ($_[0] // '') =~ /^([A-Z]: |# )/g ? $1 : '';
 		my $uid = $self->{cur_uid};
-		$warn_cb->("$pfx$uri", $uid ? ("UID:$uid") : (), "\n", @_);
+		$warn_cb->("$pfx$uri", $uid ? (" UID:$uid") : (), "\n", @_);
 	};
 	PublicInbox::NetReader::imap_each($self, $uri, \&net_cb, $self,
 					$self->{imap}->{$$uri});
@@ -451,7 +451,7 @@ sub watch_nntp_fetch_all ($$) {
 	local $SIG{__WARN__} = sub {
 		my $pfx = ($_[0] // '') =~ /^([A-Z]: |# )/g ? $1 : '';
 		my $art = $self->{cur_uid};
-		$warn_cb->("$pfx$uri", $art ? ("ARTICLE $art") : (), "\n", @_);
+		$warn_cb->("$pfx$uri", $art ? (" ARTICLE $art") : (), "\n", @_);
 	};
 	for $uri (@$uris) {
 		PublicInbox::NetReader::nntp_each($self, $uri, \&net_cb, $self,

      parent reply	other threads:[~2023-03-13 19:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-13 19:38 [PATCH 0/3] watch-related IMAP/NNTP tweaks Eric Wong
2023-03-13 19:38 ` [PATCH 1/3] use v5.12 for various network client-side packages Eric Wong
2023-03-13 19:38 ` [PATCH 2/3] spamcheck: use v5.12 and golf Eric Wong
2023-03-13 19:38 ` Eric Wong [this message]

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: https://public-inbox.org/README

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

  git send-email \
    --in-reply-to=20230313193827.3635690-4-e@80x24.org \
    --to=e@80x24.org \
    --cc=meta@public-inbox.org \
    /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/public-inbox.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).