Equivalent of os.resultof(...) in LaTeX
3 Nov
2014
3 Nov
'14
12:42 p.m.
Hi, Just short question: what's the equivalent in latex of \ctxlua{context(os.resultof("sha256sum \jobname.conTeXt | cut -c -5"))} ? Thanks in advance, Xan
3 Nov
3 Nov
1:36 p.m.
Am 03.11.2014 um 12:42 schrieb Xan:
Just short question: what's the equivalent in latex of \ctxlua{context(os.resultof("sha256sum \jobname.conTeXt | cut -c -5"))}
\documentclass{article} \begin{document} \directlua{ local handle = io.popen("sha256sum \jobname.tex | cut -c -5","r") if handle then local result = handle:read("*all") or "" handle:close() tex.print(result) end } \end{document} or load l-os.lua, then the command os.resultof is available. Herbert
3702
Age (days ago)
3702
Last active (days ago)
1 comments
2 participants
participants (2)
-
Herbert Voss
-
Xan