emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Adam Spiers <orgmode@adamspiers.org>
To: org-mode mailing list <emacs-orgmode@gnu.org>
Subject: Re: BUG: org-open-file fails with multiple %s in mailcap entry
Date: Thu, 3 Jan 2008 12:41:01 +0000	[thread overview]
Message-ID: <20080103124101.GE18716@atlantic.linksys.moosehall> (raw)
In-Reply-To: <A755D76B-9328-474F-9F06-1FEB276D8C7D@gmail.com>

On Thu, Jan 03, 2008 at 01:33:16PM +0100, Carsten Dominik wrote:
> On Dec 22, 2007, at 1:30 PM, Adam Spiers wrote:
> >The use of format in org-open-file assumes that there will only ever
> >be a single '%s' in a mailcap entry:
> >
> >   (cond
> >    ((and (stringp cmd) (not (string-match "^\\s-*$" cmd)))
> >     ;; Remove quotes around the file name - we'll use
> >    shell-quote-argument.
> >     (if (string-match "['\"]%s['\"]" cmd)
> >       (setq cmd (replace-match "%s" t t cmd)))
> >     (setq cmd (format cmd (shell-quote-argument file)))
> >
> >However this is not necessarily the case, e.g. I have

[snipped]

> What are you proposing?

Simply that every occurrence of '%s' be replaced by the file, not just
the first one.

  reply	other threads:[~2008-01-03 12:41 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-12-22 12:30 BUG: org-open-file fails with multiple %s in mailcap entry Adam Spiers
2008-01-03 12:33 ` Carsten Dominik
2008-01-03 12:41   ` Adam Spiers [this message]
2008-01-03 12:51     ` Carsten Dominik

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

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

  git send-email \
    --in-reply-to=20080103124101.GE18716@atlantic.linksys.moosehall \
    --to=orgmode@adamspiers.org \
    --cc=emacs-orgmode@gnu.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://git.savannah.gnu.org/cgit/emacs/org-mode.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).