On Fri, Jun 12, 2020 at 11:53:24AM +0100, Chris Green wrote:
I have a small script to handle PDF (among other) attachments which is
called via mailcap.

The mailcap entry is simply:-

   application/pdf;  /home/chris/bin/muttfox %s

The muttfox script gives the PDF file to firefox to be viewed.

This works fine *except* when there are spaces in the filename,
something is changing the spaces in the filename to underscores before
the name is handed to muttfox in the %s parameter.

Mutt does this for received email attachments automatically, but the filename itself should have underscores too. What do you mean by it not "working"?

So what is changing the spaces to underscores?  Does mutt do it and,
if so, is there a parameter setting to change what it does?

$mailcap_sanitize appears to be applied to %{} and %t expandos, but %s is always sanitized regardless of the setting.

--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C  5308 ADEF 7684 8031 6BDA

Attachment: signature.asc
Description: PGP signature

Reply via email to