emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: shell-command - missing shell-quote-argument for program?


From: Thomas Link
Subject: Re: shell-command - missing shell-quote-argument for program?
Date: Sat, 14 Oct 2006 09:13:34 +0200
User-agent: Thunderbird 1.5.0.7 (Windows/20060909)


Yes, I missed filesets-quote. It is used in filesets-get-quoted-selection. This is in turned used only in filesets-command:

   ("Grep <<selection>>"
    "grep"
    ("-n " filesets-get-quoted-selection " " "<<file-name>>"))

This is a shell command so in filesets-get-quoted-selection I think that shell-quote-argument should be used.
You mustn't forget that this variable may also contain lisp function, so using shell-quote-argument all the time probably isn't ok.
filesets-rum-cmd--repl-fn
The idea of this function is not only to fill in file names but to provide some kind of template language. Eg in the last version of filesets (somewhere on the web but which relies on some personal xemacs-compatibility-library & makes use of cl which is why RMS rejected it), this function knows two additional patterns: <file-list> and <<file-list>>. I'd think that with time somebody might want to have other patterns which is why I personally wouldn't move quoting to filesets-rum-cmd.

BTW the optional argument in (defun filesets-run-cmd--repl-fn (arg &optional format-fn) should not be optional I think. Leaving it out will result in (funcall nil ...).
What was I thinking.


        

        
                
___________________________________________________________ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de





reply via email to

[Prev in Thread] Current Thread [Next in Thread]