[NTG-context] ctxtools.rb (was Re: Context 2006.08.08 released )

Sanjoy Mahajan sanjoy at mrao.cam.ac.uk
Tue Aug 8 22:56:42 CEST 2006


The latest ctxtools.rb has:

        def locatedlocaltree
            tree = `kpsewhich --expand-path $TEXMFLOCAL`.chomp rescue
            unless tree && FileTest.directory?(tree) then
                tree = `kpsewhich --expand-path $TEXMF`.chomp rescue
            return tree

I know the Windows/Unix quoting isn't sorted out, but another problem
is with --expand-path.  If the
  kpsewhich --expand-path $TEXMF

line would get run here (with '$TEXMF'), it would produce


which would eventually become the argument of an unhappy Dir.chdir().
Should localtedlocaltree() extract the first component before doing
'return tree'?


`Never underestimate the evil of which men of power are capable.'
         --Bertrand Russell, _War Crimes in Vietnam_, chapter 1.

More information about the ntg-context mailing list