unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: David Bremner <david@tethera.net>
To: notmuch@notmuchmail.org
Cc: Stefano Zacchiroli <zack@debian.org>
Subject: [Kevin McCarthy] Bug#966100: notmuch-mutt: symlinking now fails for indexed mailboxes with a space in the name
Date: Thu, 23 Jul 2020 06:50:29 -0300	[thread overview]
Message-ID: <87eep2o90a.fsf@tethera.net> (raw)
In-Reply-To: 159546998738.232977.10166967333633103899.reportbug@afu.lan

[-- Attachment #1: Type: message/rfc822, Size: 10219 bytes --]

From: Kevin McCarthy <kevin@8t8.us>
To: Debian Bug Tracking System <submit@bugs.debian.org>
Subject: Bug#966100: notmuch-mutt: symlinking now fails for indexed mailboxes with a space in the name
Date: Wed, 22 Jul 2020 19:06:27 -0700
Message-ID: <159546998738.232977.10166967333633103899.reportbug@afu.lan>

Package: notmuch-mutt
Version: 0.30-1
Severity: important
Tags: upstream

Dear Maintainer,

After recently updating from stable to testing, notmuch-mutt search
and thread commands stopped including results from my "Sent Items"
maildir folder.  There are broken links in the results folder, and
symlink error messages in the terminal window after exiting mutt.

I tracked this down to upstream commit
<https://git.notmuchmail.org/git?p=notmuch;a=commitdiff;h=1fcf068e331b9b79e14f79c8b126711fc3d72cbb>
but unfortunately my shell-fu is not good enough to understand exactly
why the new version isn't working.

If I manually swap revert the diff then my Sent Items results start
working again.  So somehow the backslash-escaping works for xargs but
not for the shell while/read loop.

Here's the part of the commit above causing the breakage.

- - - - - - - - -
diff --git a/contrib/notmuch-mutt/notmuch-mutt b/contrib/notmuch-mutt/notmuch-mutt
index 0e46a8c1b95e76163eed68694aa5a1a973c8b371..d33223bdd88e776acf79ae8b4ba2703ff1e6cc58 100755 (executable)
--- a/contrib/notmuch-mutt/notmuch-mutt
+++ b/contrib/notmuch-mutt/notmuch-mutt
@@ -50,7 +50,7 @@ sub search($$$) {
     empty_maildir($maildir);
     system("notmuch search --output=files $dup_option $query"
           . " | sed -e 's: :\\\\ :g'"
-          . " | xargs -r -I searchoutput ln -s searchoutput $maildir/cur/");
+          . " | while IFS= read -r searchoutput; do ln -s \$searchoutput $maildir/cur/; done");
 }
 
 sub prompt($$) {
- - - - - - - - -


-- System Information:
Debian Release: bullseye/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)

Kernel: Linux 5.7.0-1-amd64 (SMP w/16 CPU threads)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages notmuch-mutt depends on:
ii  libmail-box-perl           3.008-1
ii  libmailtools-perl          2.21-1
ii  libstring-shellquote-perl  1.04-1
ii  libterm-readline-gnu-perl  1.36-2+b1
ii  notmuch                    0.30-1
ii  perl                       5.30.3-4

Versions of packages notmuch-mutt recommends:
pn  mutt  <none>

notmuch-mutt suggests no packages.

-- no debconf information

[-- Attachment #2: Type: text/plain, Size: 0 bytes --]



       reply	other threads:[~2020-07-23  9:50 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <159546998738.232977.10166967333633103899.reportbug@afu.lan>
2020-07-23  9:50 ` David Bremner [this message]
2020-07-23 10:45   ` [Kevin McCarthy] Bug#966100: notmuch-mutt: symlinking now fails for indexed mailboxes with a space in the name Stefano Zacchiroli
2020-07-26 21:10     ` Greg Anders
2020-08-01 23:22       ` David Bremner
2020-08-02 14:39         ` Greg Anders
2020-07-23 15:58   ` Tomi Ollila
2020-07-24 18:38     ` Kevin J. McCarthy

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://notmuchmail.org/

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

  git send-email \
    --in-reply-to=87eep2o90a.fsf@tethera.net \
    --to=david@tethera.net \
    --cc=notmuch@notmuchmail.org \
    --cc=zack@debian.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://yhetil.org/notmuch.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).