From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/76184 Path: news.gmane.org!not-for-mail From: =?iso-8859-2?B?UHJvY2jhemthIEx1a+G5IEluZy4gLSBQb250ZXggcy4gci4gby4=?= Newsgroups: gmane.comp.tex.context Subject: Re: Problem calling system Date: Tue, 15 May 2012 10:34:52 +0200 Message-ID: References: <4FB0DA4A.6090302@wxs.nl> <4FB2107B.2090008@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-2"; Format="flowed"; DelSp="yes" Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1337070923 21374 80.91.229.3 (15 May 2012 08:35:23 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 15 May 2012 08:35:23 +0000 (UTC) To: "mailing list for ConTeXt users" , "Hans Hagen" Original-X-From: ntg-context-bounces@ntg.nl Tue May 15 10:35:18 2012 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SUDDx-0005M9-IV for gctc-ntg-context-518@m.gmane.org; Tue, 15 May 2012 10:35:17 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 2456B101E9; Tue, 15 May 2012 10:35:17 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with LMTP id A2bguDBytryM; Tue, 15 May 2012 10:35:11 +0200 (CEST) Original-Received: from [127.0.0.1] (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id EA125101E0; Tue, 15 May 2012 10:35:10 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 0F838101E0 for ; Tue, 15 May 2012 10:35:10 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (localhost [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 8xHP3fZ2WiCI for ; Tue, 15 May 2012 10:35:04 +0200 (CEST) Original-Received: from filter2-til.mf.surf.net (filter2-til.mf.surf.net [194.171.167.218]) by balder.ntg.nl (Postfix) with ESMTP id 052EA101CF for ; Tue, 15 May 2012 10:35:03 +0200 (CEST) Original-Received: from mail.pontex.cz (mail.pontex.cz [89.233.168.98]) by filter2-til.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id q4F8Z05c002060 for ; Tue, 15 May 2012 10:35:02 +0200 Original-Received: from localhost ([127.0.0.1]) by mail.pontex.cz (Kerio MailServer 6.6.2); Tue, 15 May 2012 10:34:58 +0200 In-Reply-To: <4FB2107B.2090008@wxs.nl> User-Agent: Opera Mail/11.62 (Win32) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=89.233.168.98; country=CZ; latitude=49.7500; longitude=15.5000; http://maps.google.com/maps?q=49.7500,15.5000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0THa8z0EF - 73cc0ef6bb3f - 20120515 (trained as not-spam) X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.218 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:76184 Archived-At: > probably some os.execute parsing ... Do you mean Lua itself does the parsing and substitution? I guessed [lua]te= x core... When I try to call on the command line: " C:\Lukas\ConTeXt\TestDDv>lua Lua 5.1.4 Copyright (C) 1994-2008 Lua.org, PUC-Rio > os.execute([[lua -e "print 'WWW'"]]) WWW > os.execute([[echo lua -e "print 'WWW'"]]) lua -e "print 'WWW'" > =3Dos.exec nil > =3Dos.spawn nil > " - There is no '/" substitution in standalone Lua (?!). > does os.exec or os.spawn work ok? Well, the 'os.exec' works, in condition that it is called with "cmd /c": ---- \ctxlua{os.execute([[echo lua -e "print 'EXECUTE'"]])} \ctxlua{os.exec([[cmd.exe /c echo lua -e "print 'EXEC'"]])} \ctxlua{os.spawn([[cmd.exe /c echo lua -e "print 'SPAWN'"]])} \starttext A \stoptext ---- Gives: " ... languages > language en is active lua -e "print "EXECUTE"" lua -e "print 'EXEC'" system | total runtime: 0.609 " Interesting that the string to be passed to 'os.exec' keeps ' whilst that t= o 'os.execute' doesn't. Why this happens? Anyhow, thanks for the idea with 'os.exec'. Best regards, Lukas -- = Ing. Luk=E1=B9 Proch=E1zka [mailto:LPr@pontex.cz] Pontex s. r. o. [mailto:pontex@pontex.cz] [http://www.pontex.cz] Bezov=E1 1658 147 14 Praha 4 Tel: +420 244 062 238 Fax: +420 244 461 038 ___________________________________________________________________________= ________ If your question is of interest to others as well, please add an entry to t= he Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-cont= ext webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________= ________