Re: [NTG-context] file name resolving for lua files

2009-12-18 Thread Hans Hagen

Aditya Mahajan wrote:

On Thu, 17 Dec 2009, Hans Hagen wrote:


Aditya Mahajan wrote:

path ... i think that your match is related to the more or less random 
way paths are created under


$TEXMF/scripts/context//

normally stubs come after lua but maybe not on your machine

so, we might better use this:

$TEXMF/scripts/context/{lua,ruby,perl}//


Thanks. I changed TEXMFSCRIPTS in texmf.cnf to include the specific 
directories, and now luatools finds the correct file and --selfupdate 
works.



(i cc mojca for the minimals and taco for tex live)

normally this is not that important as there is only one instance ..


Do you mean that the stubs director should not have mtxrun.lua? I have

$find /opt/experimental -name 'mtxrun.lua'
/opt/experimental/tex/texmf-context/scripts/context/stubs/mswin/mtxrun.lua
/opt/experimental/tex/texmf-context/scripts/context/lua/mtxrun.lua


eh ... there is no stub on your machine, just mtxrun (without suffix) 
copied to bin, on windows there is mtxrun.exe and mtxrun.lua in the bin 
path


i just put duplicates into mswin/stubs for convenience

Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Otared Kavian
Hi Aditya,

On my machine (Mac OS X) the Minimals are installed and when trying what you 
suggest I get the correct path:

localhost:~ kavian$ luatools --locate mtxrun.lua
/context-minimal/tex/texmf-context/scripts/context/lua/mtxrun.lua

localhost:~ kavian$ texmfstart --locate mtxrun.lua
/context-minimal/tex/texmf-context/scripts/context/lua/mtxrun.lua
localhost:~ kavian$ 

I remember that a long time ago when I was using texlive, at some point the 
issues with scripts being in a stubs subdirectory of context appeared, but 
don't remember how the issue was fixed (maybe Mojca or Hans did something magic 
to solve it?).

Best regards: OK

On 16 déc. 2009, at 16:16, Aditya Mahajan wrote:

 Hi,
 
 I have noticed that my local context update scripts were not always working 
 correctly. In particular, the mtxrun and luatools file never got updated. The 
 reason is the following.
 
 When I run mtxrun --selfupdate I get
 
mtxrun --selfupdate
MTXrun | fileio: to be replaced old script
/opt/experimental/tex/texmf-linux-64/bin/mtxrun
MTXrun | fileio: using suffix based filetype 'texmfscripts'
MTXrun | fileio: checking new script
/opt/experimental/tex/texmf-context/scripts/context/stubs/mswin/mtxrun.lua
MTXrun | fileio: new script should come from scripts/context/lua
 
 So, mtxrun is trying to replace mtxrun from the stubs directory. In fact, if 
 I get the same result from
 
luatools --locate mtxrun.lua
/opt/experimental/tex/texmf-context/scripts/context/stubs/mswin/mtxrun.lua
 
 Something is wrong with the search logic as texmfstart also gets this wrong.
 
texmfstart --locate mtxrun.lua
/opt/experimental/tex/texmf-context/scripts/context/stubs/mswin/mtxrun.lua%
 
 However, kpsewhich works correctly.
 
kpsewhich mtxrun.lua
/opt/experimental/tex/texmf-context/scripts/context/lua/mtxrun.lua
 
 Do others also get the same result? Any idea what is going wrong here?
 
 Aditya
 
 ___
 If your question is of interest to others as well, please add an entry to the 
 Wiki!
 
 maillist : ntg-context@ntg.nl / 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
 ___

%%
Otared Kavian
Département de Mathématiques
Université de Versailles Saint-Quentin
Bâtiment Fermat
45 aveue des Etats Unis
78035 Versailles cedex

Téléphone: +33 1 39 25 46 42
Secrétariat: +33 1 39 25 46 44 
Secrétariat: +33 1 39 25 46 46

e-mail: otared.kav...@math.uvsq.fr



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

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Aditya Mahajan

On Thu, 17 Dec 2009, Otared Kavian wrote:


Hi Aditya,

On my machine (Mac OS X) the Minimals are installed and when trying what you 
suggest I get the correct path:

localhost:~ kavian$ luatools --locate mtxrun.lua
/context-minimal/tex/texmf-context/scripts/context/lua/mtxrun.lua

localhost:~ kavian$ texmfstart --locate mtxrun.lua
/context-minimal/tex/texmf-context/scripts/context/lua/mtxrun.lua
localhost:~ kavian$


Can anyone on linux 64 confirm this? I want to cofirm if this is something 
general or specific to my machine.


I remember that a long time ago when I was using texlive, at some point 
the issues with scripts being in a stubs subdirectory of context 
appeared, but don't remember how the issue was fixed (maybe Mojca or 
Hans did something magic to solve it?).


I get the correct result with TL09, but incorrect result on two differnt 
minimal installations.


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

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Hans Hagen

Aditya Mahajan wrote:

On Thu, 17 Dec 2009, Otared Kavian wrote:


Hi Aditya,

On my machine (Mac OS X) the Minimals are installed and when trying 
what you suggest I get the correct path:


localhost:~ kavian$ luatools --locate mtxrun.lua
/context-minimal/tex/texmf-context/scripts/context/lua/mtxrun.lua

localhost:~ kavian$ texmfstart --locate mtxrun.lua
/context-minimal/tex/texmf-context/scripts/context/lua/mtxrun.lua
localhost:~ kavian$


Can anyone on linux 64 confirm this? I want to cofirm if this is 
something general or specific to my machine.


I remember that a long time ago when I was using texlive, at some 
point the issues with scripts being in a stubs subdirectory of 
context appeared, but don't remember how the issue was fixed (maybe 
Mojca or Hans did something magic to solve it?).


I get the correct result with TL09, but incorrect result on two differnt 
minimal installations.


can you run with 
--track=resolvers.locating,resolvers.details,resolvers.expansions


(or --resolvers=*)

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Hans Hagen

Aditya Mahajan wrote:

is attached. I don't know know to interpret the result, but nothing 
seems glaringly wrong.


need some thinking ...

anyhow, i get

LuaTools | fileio: checking filename 'mtxrun.lua'
LuaTools | fileio: file './mtxrun.lua' is not readable
LuaTools | fileio: file 'c:/data/develop/context/lua/mtxrun.lua' is readable
LuaTools | fileio: found 'c:/data/develop/context/lua/mtxrun.lua' by 
scanning

LuaTools | fileio: c:/data/develop/context/lua/mtxrun.lua

btw ... we can remove the etex, pdfetex and omega entries in the cnf 
file i think (i wonder if there's anything useful in those subpaths)


Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Hans Hagen

Aditya Mahajan wrote:

path ... i think that your match is related to the more or less random 
way paths are created under


$TEXMF/scripts/context//

normally stubs come after lua but maybe not on your machine

so, we might better use this:

$TEXMF/scripts/context/{lua,ruby,perl}//

(i cc mojca for the minimals and taco for tex live)

normally this is not that important as there is only one instance ..

also, selfupdate should not be influenced by that as it should take the 
original


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
 tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Aditya Mahajan

On Thu, 17 Dec 2009, Hans Hagen wrote:


Aditya Mahajan wrote:

path ... i think that your match is related to the more or less random way 
paths are created under


$TEXMF/scripts/context//

normally stubs come after lua but maybe not on your machine

so, we might better use this:

$TEXMF/scripts/context/{lua,ruby,perl}//


Thanks. I changed TEXMFSCRIPTS in texmf.cnf to include the specific 
directories, and now luatools finds the correct file and --selfupdate 
works.



(i cc mojca for the minimals and taco for tex live)

normally this is not that important as there is only one instance ..


Do you mean that the stubs director should not have mtxrun.lua? I have

$find /opt/experimental -name 'mtxrun.lua'
/opt/experimental/tex/texmf-context/scripts/context/stubs/mswin/mtxrun.lua
/opt/experimental/tex/texmf-context/scripts/context/lua/mtxrun.lua

also, selfupdate should not be influenced by that as it should take the 
original


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

maillist : ntg-context@ntg.nl / 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
___


Re: [NTG-context] file name resolving for lua files

2009-12-17 Thread Aditya Mahajan
Also, mtxrun and luatools do not set the exit flag correctly in case of 
a failure. For example, (in the old setup)


$mtxrun --selfupdate 
MTXrun | fileio: to be replaced old script /opt/context-minimals/texmf-linux-64/bin/mtxrun

MTXrun | fileio: using suffix based filetype 'texmfscripts'
MTXrun | fileio: checking new script 
/opt/context-minimals/texmf-context/scripts/context/stubs/mswin/mtxrun.lua
MTXrun | fileio: new script should come from scripts/context/lua

$ echo $?
0

Because of this, I never noticed that something was going wrong in my 
update scripts.


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

maillist : ntg-context@ntg.nl / 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
___