send " ' " (single quote character) via system command?

Kenneth Brody kenbrody at spamcop.net
Sat Dec 6 12:44:36 PST 2014


On 12/6/2014 2:45 PM, Bill Campbell wrote:
> On Fri, Dec 05, 2014, James Flanagan wrote:
>> FreeBSD 9.2
>> Filepro 5.7.0.03
[...]
>> :exists(html_file) eq "0":unix="cat /www/template.html | sed \'s/XXXXX/"{1{"/g\' >"<html_file:
>> ::msgbox unix:

You don't say what doesn't work.  (I assume you actually have a SYSTEM 
command somewhere?)

> That script is a good example of the useless use of cat, and
> wouldn't work in any case with a < redirect and a pipe.

Nit:

    There is no "< redirect".  The "<" is the filePro 
concatenate-and-leave-one-space operator.

Dropping the useless-cat, this should work (though I'm not on a *nix system 
at the moment to test it):

     unix = "sed 's/XXXXX/" { 1 { "/g' </www/template.html >" { html_file

Again, the OP doesn't explain what "doesn't work".

> I would put your sed into a script then call the script avoiding
> any quoting issues.


-- 
Kenneth Brody


More information about the Filepro-list mailing list