Hi,
I need to read the standard output of an external command. This is
what I came up with:
\starttext
\startluacode
f = io.popen ls
context(f:read *a)
\stopluacode
\stoptext
It works with luajittex, plain lua5.1 and lua5.2, but it fails with
a current luatex:
! LuaTeX error
On 4/14/2013 12:06 PM, Marco Patzer wrote:
Hi,
I need to read the standard output of an external command. This is
what I came up with:
\starttext
\startluacode
f = io.popen ls
context(f:read *a)
\stopluacode
\stoptext
context(os.resultof(ls))
It works with luajittex, plain