user/dev discussion of public-inbox itself
 help / color / mirror / code / Atom feed
From: Eric Wong <>
Subject: [PATCH 1/4] extindex: use localtime to display lock time
Date: Sat, 16 Oct 2021 22:52:47 -1100	[thread overview]
Message-ID: <> (raw)
In-Reply-To: <>

Since this is intended for use on the command-line,
include TZ offset in time and try to shorten the
message a bit so it wraps less on a terminal.
 lib/PublicInbox/ | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/lib/PublicInbox/ b/lib/PublicInbox/
index 69d048fb7342..67d720368922 100644
--- a/lib/PublicInbox/
+++ b/lib/PublicInbox/
@@ -719,11 +719,12 @@ sub eidxq_lock_acquire ($) {
 		return $locked if $locked eq $cur;
 	my ($pid, $time, $euid, $ident) = split(/-/, $cur, 4);
-	my $t = strftime('%Y-%m-%d %k:%M:%S', gmtime($time));
+	my $t = strftime('%Y-%m-%d %k:%M %z', localtime($time));
+	local $self->{current_info} = 'eidxq';
 	if ($euid == $> && $ident eq host_ident) {
 		if (kill(0, $pid)) {
 			warn <<EOM; return;
-I: PID:$pid (re)indexing Xapian since $t, it will continue our work
+I: PID:$pid (re)indexing since $t, it will continue our work
 		if ($!{ESRCH}) {

  reply	other threads:[~2021-10-17  9:52 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-10-17  9:52 [PATCH 0/4] extindex tweaks and small fixes Eric Wong
2021-10-17  9:52 ` Eric Wong [this message]
2021-10-17  9:52 ` [PATCH 2/4] extindex: retry sync_inbox before reindex Eric Wong
2021-10-17  9:52 ` [PATCH 3/4] extindex: guard against false mismatch unrefs Eric Wong
2021-10-17  9:52 ` [PATCH 4/4] extindex: better locations for {quit} checks Eric Wong

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:

  List information:

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

  git send-email \ \ \ \
    --subject='Re: [PATCH 1/4] extindex: use localtime to display lock time' \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Code repositories for project(s) associated with this inbox:

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).