[tex-live] TEXINPUTS on windows

Reinhard Kotucha reinhard.kotucha at web.de
Sun Nov 7 01:49:40 CET 2010


Hi,
people ask for new features again and again though they don't make
the slightest attempt to read the documentation in order to find out
what TeX Live provides already.

As far as I understand Lars, his problem is that he can't expect from
his users that they are aware of TEXMFHOME.  Then Norbert said that
tlmgr already provides facilities to add an extra texmf tree, but Lars
can't expect from his users to run tlmgr --help.  Sure, Norbert can
add new features to tlmgr and Lars will tell us that his users aren't
aware of them...

  ...\expandafter\recurse\fi

Is it reasonable then to add new features only because people aren't
aware of what already exists?  IMO new features should be added only
if things can't be done with the system as it is, and *not* because
people are unable/unwilling to read documentation.

It was mentioned how easy everything is with MikTeX.  Yes, everything
is easier indeed because it's a single-user system.  There is *one*
user and *one* configuration file.

TeX Live is a multi-user system and usually a mortal user can't modify
the system-wide texmf.cnf file.  I'm wondering why people mentioned
TEXMFLOCAL in this thread at all.  The appropriate directory for
per-user data is TEXMFHOME.

What I absolutely don't understand is the recommendation to set an
environment variable (adding a new texmf tree) instead of simply copy
the files to TEXMFHOME.  Sigh, I'm aware that many Windows users are
unable to copy files from one directory to another one, but on the
other hand I know how painful it is to explain someone how to set
environment variables on this ever so user-friendly operating system.

Ulrike mentioned an interesting problem: Someone installs a
TDS-compliant ZIP file and wants to remove it later.  I don't think
that an extra texmf tree is needed.  The ZIP file contains the
information where to put files, the same information can be used to
remove the files.

A few days ago I had exactly this problem in mind and wrote such an
uninstaller.  It was designed for .tar.gz files but it can be adapted
for ZIP files easily.  See the code below.  It's written in texlua, so
I'm sure it works under MikTeX as well.

Regards,
  Reinhard


#! /usr/bin/env texlua
--*- Lua -*-

-- Copyright 2010 Reinhard Kotucha <reinhard.kotucha at web.de>
--
-- You may freely use, modify and/or distribute this file.

function usage ()
   io.stderr:write ('Usage:\n' .. '\t' .. arg[0] .. ' <file>.tar.gz\n') 
   os.exit (1)
end

if #arg < 1 then usage() end
if not lfs.isfile (arg[1]) then usage() end

f = assert (io.popen ('tar -tzf ' .. arg[1]), 'r')
  
for file in f:lines() do
   if not string.match (file, '\/$') then -- no dir
      if lfs.isfile(file) then
	 print ('removing '.. file)
	 os.remove (file)
      else
	 io.stderr:write ('No such file: ' .. file .. '\n')
      end
   end
end

f:close()



-- 
----------------------------------------------------------------------------
Reinhard Kotucha			              Phone: +49-511-3373112
Marschnerstr. 25
D-30167 Hannover	                      mailto:reinhard.kotucha at web.de
----------------------------------------------------------------------------
Microsoft isn't the answer. Microsoft is the question, and the answer is NO.
----------------------------------------------------------------------------


More information about the tex-live mailing list