From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Barry Margolin Newsgroups: gmane.emacs.help Subject: Re: Redirectin output of call-process to a file. Date: Wed, 22 May 2013 13:07:40 -0400 Organization: A noiseless patient Spider Message-ID: References: <20130522150337.2e98e8ba@pcolivier.chezmoi.net> NNTP-Posting-Host: plane.gmane.org X-Trace: ger.gmane.org 1369242749 355 80.91.229.3 (22 May 2013 17:12:29 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 22 May 2013 17:12:29 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed May 22 19:12:29 2013 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UfCaR-0004mg-0F for geh-help-gnu-emacs@m.gmane.org; Wed, 22 May 2013 19:12:27 +0200 Original-Received: from localhost ([::1]:40282 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UfCaQ-0005Ie-Il for geh-help-gnu-emacs@m.gmane.org; Wed, 22 May 2013 13:12:26 -0400 Original-Path: usenet.stanford.edu!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!feeder.erje.net!eu.feeder.erje.net!eternal-september.org!feeder.eternal-september.org!mx05.eternal-september.org!barmar.motzarella.org!.POSTED!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 23 Injection-Info: barmar.motzarella.org; posting-host="2be9e9f5dd9af768b8861af71b85fc28"; logging-data="30243"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19zjo6a2GtMkEZxxF2RKrup" User-Agent: MT-NewsWatcher/3.5.3b3 (Intel Mac OS X) Cancel-Lock: sha1:wYyO/cIrgNyysIfjjLU4HgCjIqI= Original-Xref: usenet.stanford.edu gnu.emacs.help:198718 X-Mailman-Approved-At: Wed, 22 May 2013 13:12:17 -0400 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:90984 Archived-At: In article <20130522150337.2e98e8ba@pcolivier.chezmoi.net>, Olive wrote: > I am executing the following command: > > (call-process "/usr/bin/echo" nil (:file "/tmp/test.txt") nil "hello") > > According tothe documentaion this should redirect the output of th eproces to > the file "/tmp/test.txt" but I have this error: > > Symbol's function definition is void: :file > > What am I doingwrong here? I use emcs 24.3.1 on GNU/Linux. You need to quote the list, to prevent it from being evaluated as a function call: (call-process "/usr/bin/echo" nil '(:file "/tmp/test.txt") nil "hello") -- Barry Margolin, barmar@alum.mit.edu Arlington, MA *** PLEASE post questions in newsgroups, not directly to me ***