[Python-Dev] installing IDLE & other Tools

Jeremy Hylton jeremy@alum.mit.edu
Tue, 14 Nov 2000 21:13:36 -0500 (EST)


>>>>> "GvR" == Guido van Rossum <guido@python.org> writes:

  >> > I don't know how to package up idle cleanly, though.  I need to
  >> > decide what to install and where to install it.  The Tools/idle
  >> > directory is nominally a package, but it doesn't seem like that
  >> > will help much for installing it.  If we want to call the
  >> > executable script idle.py, it will clash with the idle package
  >> > name.  Any advice here?  It doesn't seem like there is any
  >> > obvious way to "install" IDLE; it looks like it is intended to
  >> > be run out of the source directory.
  >>

  GvR> For Windows, the IDLE problem is solved: it's installed in
  GvR> directory <topdir>/Tools/idle/ and there's a link to it in the
  GvR> start menu.  It's not directly accessible from the command line
  GvR> -- but on Windows, nobody cares about the command line.

  GvR> Maybe we can extend this idea to Unix.  Concrete proposal:
  GvR> install IDLE as
  GvR> <prefix>/lib/python<version>/site-packages/Tools/idle/, and
  GvR> place a symlink or 2-line bootstrap script in
  GvR> <prefix>/bin/idle.

How about
<prefix>/lib/python<version>/Tools/idle
instead.  I suggest the change to support an until-now-implicit policy
that anything in site-packages actually be a package.  If things in
site-packages aren't supposed to be packages, it ought to be called
something like site-tools <0.2 wink>.

  GvR> The introduction of the extra directory level "Tools" implies
  GvR> that idle is not importable as a package from regular Python.
  GvR> This is how I want it -- otherwise I could/would have made IDLE
  GvR> a package in the Lib/lib-tk directory instead of a directory in
  GvR> Tools.

I think the extra Tools directory still implies this, even if it isn't
in site-packages.

  GvR> I'd gladly accept a contribution of a setup.py file that does
  GvR> this for me.  (I looked at the distutils manual for a bit but
  GvR> decided that I'd have to read it cover-to-cover to figure out
  GvR> whether what I want is even possible...)

Is there a reason why IDLE has this peculiar installation process?
Might there be a better way to do it now that we have distutils.  If
there is, we could put it in PEP 42.

Jeremy