Re: [NTG-context] possible problem with setuptex

2009-06-12 Thread Mojca Miklavec
On Fri, Jun 12, 2009 at 07:25, Peter Münster wrote:
 On Fri, 12 Jun 2009, Mojca Miklavec wrote:

 I left TEXMFCACHE variable as an excuse for not adding texmfcnf.lua to
 the distribution. (Though in theory it's still not needed, you just
 need to regenerate the database since LuaTeX doesn't know about the
 location of your old cache.)

 I have added the file now.

 Great, it works now. Clean solution!

 But I'm asking myself, how SELFAUTOPARENT works:
 luatex is here: /opt/context/tex/texmf-linux-64/bin/luatex
 So it seems, that SELFAUTOPARENT is /opt/context/tex

Yes.

 But I would have guessed that it's /opt/context/tex/texmf-linux-64 ...

No, that's SELFAUTODIR.

 I even suggest, to suppress setuptex and only write in the readme/wiki,
 that the PATH must be adjusted so that context can be found, that's all.

We could issue a warning or we could put something at the end of
first-setup.sh (that needs to be renamed anyway) to tell users that
they should either adjust path or use the script.

I might be having weird habits, but I really like being able to have a
simple single command that switches the TeX tree.

export PATH=/something/very/long/:$PATH costs more effort to type than
just . setuptex :) :) :)

Wiki could/should be modified for sure. One day I need to revise all
kinds of instructions for different installations ... (finishing study
in time has a high priority at the moment).

The initial idea of setuptex was to shield all the environmental
variables that have been set by tetex. I suspect that cleaning up
setuptex had a consequence that it's not able to shield tetex any
more, but nobody has complained so far ...

Mojca
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-12 Thread Taco Hoekwater


Mojca Miklavec wrote:

 But I'm asking myself, how SELFAUTOPARENT works:
 luatex is here: /opt/context/tex/texmf-linux-64/bin/luatex
 So it seems, that SELFAUTOPARENT is /opt/context/tex
 
 Yes.
 
 But I would have guessed that it's /opt/context/tex/texmf-linux-64 ...
 
 No, that's SELFAUTODIR.

And /opt/context/tex/texmf-linux-64/bin/luatex is SELFAUTOLOC.
The somewhat confusing variable names are a historical artifact.

Best wishes,
Taco
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] possible problem with setuptex

2009-06-11 Thread Hans van der Meer
When loading minimals with a shell script it appears that setuptex  
takes arguments from the calling shell script:


script called as script --current contains:
...
source ./setuptex
...

This result in the following error message:

mktexlsr: Done.
The argument /Users/hans/TeX/context/current/tex/--current is not a  
valid TEXROOT path.
There is no file /Users/hans/TeX/context/current/tex/--current/texmf/ 
tex/plain/base/plain.tex

Setting /Users/hans/TeX/context/current/tex as TEXROOT instead.

I guess this cannot be the intent of setuptex. It was the intention to  
just use

/Users/hans/TeX/context/current/tex/
as the TEXROOT path.
Is there a simple solution?

Hans van der Meer




___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Hans Hagen

Hans van der Meer wrote:
When loading minimals with a shell script it appears that setuptex takes 
arguments from the calling shell script:


script called as script --current contains:

source ./setuptex


This result in the following error message:

mktexlsr: Done.
The argument /Users/hans/TeX/context/current/tex/--current is not a 
valid TEXROOT path.
There is no file 
/Users/hans/TeX/context/current/tex/--current/texmf/tex/plain/base/plain.tex 


Setting /Users/hans/TeX/context/current/tex as TEXROOT instead.

I guess this cannot be the intent of setuptex. It was the intention to 
just use

/Users/hans/TeX/context/current/tex/
as the TEXROOT path.
Is there a simple solution?


what is --current supposed to do? shouldn't you use:

source ./setuptex /Users/hans/TeX/context/current/tex/


-
  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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Peter Münster
On Thu, 11 Jun 2009, Hans van der Meer wrote:

 When loading minimals with a shell script it appears that setuptex takes
 arguments from the calling shell script:

Indeed. 2 solutions:

- treat or save your arguments before calling setuptex, for example:
  ARG1=$1
  ARG2=$2
  shift $#
  source /opt/context/tex/setuptex

- or setuptex should be rather an executable, that prints out the
  environment to apply, then one would do something like this:
  eval `setuptex`
  (cleaner solution, but some work to do and all minimal-users must change
  their habits...)

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Mojca Miklavec
On Thu, Jun 11, 2009 at 12:26, Hans van der Meer wrote:
 When loading minimals with a shell script it appears that setuptex takes
 arguments from the calling shell script:
 script called as script --current contains:
 ...
 source ./setuptex
 ...
 This result in the following error message:
 mktexlsr: Done.
 The argument /Users/hans/TeX/context/current/tex/--current is not a valid
 TEXROOT path.
 There is no file
 /Users/hans/TeX/context/current/tex/--current/texmf/tex/plain/base/plain.tex
 Setting /Users/hans/TeX/context/current/tex as TEXROOT instead.
 I guess this cannot be the intent of setuptex. It was the intention to just
 use
 /Users/hans/TeX/context/current/tex/
 as the TEXROOT path.
 Is there a simple solution?
 Hans van der Meer

Maybe I'm wroing, but didn't it do that already? It said
   Setting /Users/hans/TeX/context/current/tex as TEXROOT
Well, it has complained a bit, but it nevertheless did it :)

setuptex tries to be clever about acceping an argument to pass some
other path. I don't know how shell expansion works, but it might
indeed be working a bit weird.

If you wrap the script setuptex into some other script, you could just
as well only set PATH (and maybe TEXMFCACHE).

Mojca
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Mojca Miklavec
 - or setuptex should be rather an executable, that prints out the
  environment to apply, then one would do something like this:
  eval `setuptex`
  (cleaner solution, but some work to do and all minimal-users must change
  their habits...)

I theory adjusting PATH should do, but it's a nice proposal :)

Mojca
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Peter Münster
On Thu, 11 Jun 2009, Mojca Miklavec wrote:

  - or setuptex should be rather an executable, that prints out the
   environment to apply, then one would do something like this:
   eval `setuptex`
   (cleaner solution, but some work to do and all minimal-users must change
   their habits...)
 
 I theory adjusting PATH should do, but it's a nice proposal :)

So TEXMFCACHE and TEXMFOS are not needed?
And what about the praxis in contrast do the theory?

Here my little test:
unset TEXMFOS 
unset TEXMFCACHE 
context test
- MTXrun | unknown script 'context.lua' or 'mtx-context.lua'

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Mojca Miklavec
On Thu, Jun 11, 2009 at 23:25, Peter Münster wrote:
 On Thu, 11 Jun 2009, Mojca Miklavec wrote:

  - or setuptex should be rather an executable, that prints out the
   environment to apply, then one would do something like this:
   eval `setuptex`
   (cleaner solution, but some work to do and all minimal-users must change
   their habits...)

 I theory adjusting PATH should do, but it's a nice proposal :)

 So TEXMFCACHE and TEXMFOS are not needed?
 And what about the praxis in contrast do the theory?

 Here my little test:
 unset TEXMFOS
 unset TEXMFCACHE
 context test
 - MTXrun | unknown script 'context.lua' or 'mtx-context.lua'

I left TEXMFCACHE variable as an excuse for not adding texmfcnf.lua to
the distribution. (Though in theory it's still not needed, you just
need to regenerate the database since LuaTeX doesn't know about the
location of your old cache.)

I have added the file now.

I guess that TEXMFOS is not needed either.
A month ago I decided to clean up setuptex a bit and removed
everything but PATH setting ... and then the lack of TEXMFOS has
destroyed the whole evening trying to figure out why it worked on
everyone's machine but mine ... The bug has been fixed though, so ...
if you update now to fetch that additional file ... does it work then?

If yes, I'll remove the two remaining variables from setuptex. (I
might be offline for a longer period though.)

Mojca
___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] possible problem with setuptex

2009-06-11 Thread Peter Münster
On Fri, 12 Jun 2009, Mojca Miklavec wrote:

 I left TEXMFCACHE variable as an excuse for not adding texmfcnf.lua to
 the distribution. (Though in theory it's still not needed, you just
 need to regenerate the database since LuaTeX doesn't know about the
 location of your old cache.)
 
 I have added the file now.

Great, it works now. Clean solution!

But I'm asking myself, how SELFAUTOPARENT works:
luatex is here: /opt/context/tex/texmf-linux-64/bin/luatex
So it seems, that SELFAUTOPARENT is /opt/context/tex
But I would have guessed that it's /opt/context/tex/texmf-linux-64 ...

I even suggest, to suppress setuptex and only write in the readme/wiki,
that the PATH must be adjusted so that context can be found, that's all.

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/

___
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  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___