Hi Aditya.
Thanx for reply. I am sending result from output console from your example ie:
\starttext
\writestatus{test}{before calling shell command}
\immediate\write18{echo HELP}
\writestatus{test}{after calling shell command}
\stoptext

Output is below.
Regarding the call ConTeXt, I often calls it directly from the editor (PsPad) but when frequently repeated compilations, then I type commands directly from terminal (command line of windows)

Thankx for attempt to solve my problem.
Jaroslav Hajtmar


C:\$~1da\ConTeXt\ConTeXt-Tests\my_way\ScanCSV\t-scancsv_ConTeXt_module\2PabloRod
riguez5\bbb>context test

mtx-context     | warning: no (local) file './test', proceeding
mtx-context | run 1: luatex --fmt="C:/context/tex/texmf-cache/luatex-cache/c ontext/5fe67e0bfe781ce0dde776fb1556f32e/formats/luatex/cont-en" --jobname="test"
 --lua="C:/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb
1556f32e/formats/luatex/cont-en.lui" --no-parse-first-line --c:currentrun=1 --c: fulljobname="./test" --c:input="./test" --c:kindofrun=1 --c:maxnofruns=8 "cont-y
es.mkiv"
This is LuaTeX, Version beta-0.79.1 (TeX Live 2014/W32TeX) (rev 5064)
 \write18 enabled.
open source > 1 > 1 > C:/context/tex/texmf-context/tex/context/base/cont-yes
.mkiv
                >
ConTeXt ver: 2015.02.03 23:55 MKIV beta fmt: 2015.2.16 int: english/english >

                >
system          > 'cont-new.mkiv' loaded
open source > 2 > 2 > C:/context/tex/texmf-context/tex/context/base/cont-new
.mkiv
close source > 2 > 2 > C:/context/tex/texmf-context/tex/context/base/cont-new
.mkiv
system          > files > jobname 'test', input './test', result 'test'
fonts           > latin modern fonts are not preloaded
languages       > language 'en' is active
open source > 2 > 3 > C:/$~1da/ConTeXt/ConTeXt-Tests/my_way/ScanCSV/t-scancs
v_ConTeXt_module/2PabloRodriguez5/bbb/test.tex
fonts           > preloading latin modern fonts (second stage)
fonts           > 'fallback modern-designsize rm 12pt' is loaded
test            > before calling shell command
test            > after calling shell command
close source > 2 > 3 > C:/$~1da/ConTeXt/ConTeXt-Tests/my_way/ScanCSV/t-scancs
v_ConTeXt_module/2PabloRodriguez5/bbb/test.tex
close source > 1 > 3 > C:/context/tex/texmf-context/tex/context/base/cont-yes
.mkiv

mkiv lua stats  > used config file: selfautoparent:/texmf/web2c/texmfcnf.lua
mkiv lua stats > used cache path: C:/context/tex/texmf-cache/luatex-cache/conte
xt/5fe67e0bfe781ce0dde776fb1556f32e
mkiv lua stats > resource resolver: loadtime 0.012 seconds, 0 scans with scanti
me 0.000 seconds, 0 shared scans, 8 found files, scanned paths: <none>
mkiv lua stats > stored bytecode data: 364 modules (0.231 sec), 76 tables (0.00
6 sec), 440 chunks (0.237 sec)
mkiv lua stats  > running in nuts mode: yes
mkiv lua stats  > cleaned up reserved nodes: 41 nodes, 439 lists of 438
mkiv lua stats > node memory usage: 2 glue, 2 penalty, 6 attribute, 20 glue_spe
c, 2 attribute_list, 2 temp
mkiv lua stats > node list callback tasks: 6 unique task lists, 2 instances (re
)created, 3 calls
mkiv lua stats > used backend: pdf (backend for directly generating pdf output)

mkiv lua stats  > loaded patterns: en::2, load time: 0.000
mkiv lua stats  > jobdata time: 0.004 seconds saving, 0.001 seconds loading
mkiv lua stats  > callbacks: 55 direct, 241 indirect, 296 total
mkiv lua stats  > randomizer: resumed with value 0.53962828455458
mkiv lua stats > result saved in file: test.pdf, compresslevel 3, objectcompres
slevel 3
mkiv lua stats > loaded fonts: 2 files: latinmodern-math.otf, lmroman12-regular
.otf
mkiv lua stats  > fonts load time: 0.267 seconds
mkiv lua stats > used platform: win64, type: windows, binary subtree: texmf-win
64
mkiv lua stats > luatex banner: this is luatex, version beta-0.79.1 (tex live 2
014/w32tex) (rev 5064)
mkiv lua stats  > control sequences: 40426 of 65536 + 100000
mkiv lua stats > lua properties: engine: lua, used memory: 59 MB (ctx: 59 MB),
hash type: lua, hash chars: min(64,40), symbol mask: utf (¤ä╬Á¤ç)
mkiv lua stats  > runtime: 0.721 seconds

system          | total runtime: 1.095 seconds
C:\$~1da\ConTeXt\ConTeXt-Tests\my_way\ScanCSV\t-scancsv_ConTeXt_module\2PabloRod
riguez5\bbb>



And here is log file:


open source > 1 > 1 > C:/context/tex/texmf-context/tex/context/base/cont-yes.mkiv
                >
ConTeXt ver: 2015.02.03 23:55 MKIV beta fmt: 2015.2.16 int: english/english >
                >
system          > 'cont-new.mkiv' loaded
open source > 2 > 2 > C:/context/tex/texmf-context/tex/context/base/cont-new.mkiv close source > 2 > 2 > C:/context/tex/texmf-context/tex/context/base/cont-new.mkiv
system          > files > jobname 'test', input './test', result 'test'
fonts           > latin modern fonts are not preloaded
languages       > language 'en' is active
open source > 2 > 3 > C:/$~1da/ConTeXt/ConTeXt-Tests/my_way/ScanCSV/t-scancsv_ConTeXt_module/2PabloRodriguez5/bbb/test.tex
fonts           > preloading latin modern fonts (second stage)
fonts           > 'fallback modern-designsize rm 12pt' is loaded
test            > before calling shell command
test            > after calling shell command
close source > 2 > 3 > C:/$~1da/ConTeXt/ConTeXt-Tests/my_way/ScanCSV/t-scancsv_ConTeXt_module/2PabloRodriguez5/bbb/test.tex close source > 1 > 3 > C:/context/tex/texmf-context/tex/context/base/cont-yes.mkiv

system          > structure > start used structure

used structure  > text: test

system          > structure > stop used structure


system          > files > start used files

used file > 1: filename=cont-yes.mkiv filetype=tex foundname=C:/context/tex/texmf-context/tex/context/base/cont-yes.mkiv usedmethod=database used file > 2: filename=publ-imp-apa.lua filetype=lua foundname=C:/context/tex/texmf-context/tex/context/base/publ-imp-apa.lua usedmethod=database used file > 3: filename=cont-new.mkiv filetype=tex foundname=C:/context/tex/texmf-context/tex/context/base/cont-new.mkiv usedmethod=database used file > 4: filename=lang-us.lua filetype=lua foundname=C:/context/tex/texmf-context/tex/context/patterns/lang-us.lua usedmethod=database used file > 5: filename=C:\$~1da\ConTeXt\ConTeXt-Tests\my_way\ScanCSV\t-scancsv_ConTeXt_module\2PabloRodriguez5\bbb/test foundname=C:/$~1da/ConTeXt/ConTeXt-Tests/my_way/ScanCSV/t-scancsv_ConTeXt_module/2PabloRodriguez5/bbb/test.tex usedmethod=qualified used file > 6: filename=lm.lfg filetype=tex foundname=C:/context/tex/texmf-context/tex/context/fonts/lm.lfg usedmethod=database used file > 7: filename=lmroman12-regular filetype=otf format=otf foundname=C:/context/tex/texmf/fonts/opentype/public/lm/lmroman12-regular.otf usedmethod=database used file > 8: filename=latinmodern-math.otf filetype=opentypefonts foundname=C:/context/tex/texmf/fonts/opentype/public/lm-math/latinmodern-math.otf usedmethod=database

system          > files > stop used files


system          > options > start commandline options

used option     > currentrun="1"
used option     > fulljobname="./test"
used option     > input="./test"
used option     > kindofrun="1"
used option     > maxnofruns="8"
used option     > no-parse-first-line="true"

system          > options > stop commandline options

system          > options > start commandline files

used file       >    1: ./test

system          > options > stop commandline files


mkiv lua stats  > used config file: selfautoparent:/texmf/web2c/texmfcnf.lua
mkiv lua stats > used cache path: C:/context/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e mkiv lua stats > resource resolver: loadtime 0.012 seconds, 0 scans with scantime 0.000 seconds, 0 shared scans, 8 found files, scanned paths: <none> mkiv lua stats > stored bytecode data: 364 modules (0.231 sec), 76 tables (0.006 sec), 440 chunks (0.237 sec)
mkiv lua stats  > running in nuts mode: yes
mkiv lua stats  > cleaned up reserved nodes: 41 nodes, 439 lists of 438
mkiv lua stats > node memory usage: 2 glue, 2 penalty, 6 attribute, 20 glue_spec, 2 attribute_list, 2 temp mkiv lua stats > node list callback tasks: 6 unique task lists, 2 instances (re)created, 3 calls mkiv lua stats > used backend: pdf (backend for directly generating pdf output)
mkiv lua stats  > loaded patterns: en::2, load time: 0.000
mkiv lua stats  > jobdata time: 0.004 seconds saving, 0.001 seconds loading
mkiv lua stats  > callbacks: 55 direct, 241 indirect, 296 total
mkiv lua stats  > randomizer: resumed with value 0.53962828455458
mkiv lua stats > result saved in file: test.pdf, compresslevel 3, objectcompresslevel 3 mkiv lua stats > loaded fonts: 2 files: latinmodern-math.otf, lmroman12-regular.otf
mkiv lua stats  > fonts load time: 0.267 seconds
mkiv lua stats > used platform: win64, type: windows, binary subtree: texmf-win64 mkiv lua stats > luatex banner: this is luatex, version beta-0.79.1 (tex live 2014/w32tex) (rev 5064)
mkiv lua stats  > control sequences: 40426 of 65536 + 100000
mkiv lua stats > lua properties: engine: lua, used memory: 59 MB (ctx: 59 MB), hash type: lua, hash chars: min(64,40), symbol mask: utf (τεχ)
mkiv lua stats  > runtime: 0.721 seconds




Dne 16.2.2015 v 23:59 Aditya Mahajan napsal(a):
On Mon, 16 Feb 2015, Jaroslav Hajtmar wrote:

Thanx Aditya for reply.

I compile this ConTeXt file:

\starttext
\immediate\write18{context --version}
\stoptext

with last standalone version of ConTeXt (minimals). Below is the console output and log file.

write18 is enabled on your system; I don't know why the shell command does not work.

Try this instead (I assume that windows comes with the echo command):

\starttext
\writestatus{test}{before calling shell command}
\immediate\write18{echo HELP}
\writestatus{test}{after calling shell command}
\stoptext

Post only the output of the 2nd run (so that the console output is shown once and not thrice).

How are you running context? (Typing the command from a terminal, or using an IDE?)

Aditya


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : [email protected] / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to