[Idle-dev] Doc files
Bruce Sherwood
bas@andrew.cmu.edu
Mon, 08 Oct 2001 14:15:25 -0400
The idlefork project at sourceforge.net began with the IDLE version created
by Dave Scherer in the VPython context. It is now being extended, and bugs
being fixed, with the goal of becoming the version of IDLE to be
distributed with future versions of Python. The idlefork version has
reached a level of maturity that makes it feasible to use it rather than
the original VPython version, with the long-term advantage of there being
only one version of Scherer-based IDLE to maintain and extend.
In the past, the VPython installer installed Doc\VPython.html with a link
to Doc\index.html, the standard documentation home page for Python. The
original VPython version of IDLE linked to Doc\VPython.html when you
pressed F1 for help. The idlefork version links to index.html, and it would
be desirable not to change IDLE to accomodate the wider documentation needs
of Python+Visual.
In the idlefork discussion I proposed overwriting index.html with the
VPython index, and installing a copy of the Python index. But a reader
pointed out that he makes changes to the Python index (to add more
documentation links), and the VPython installer would overwrite the
changes. I think I've sorted out how to build the VPython installer so as
to preserve user changes to the standard Python Doc\index.html. If you see
a hole in my logic, please criticize! I'm using Inno Setup with Extensions
to create the installer.
1) In the Doc directory, if Python.html doesn't exist, copy index.html to
Python.html.
2) If Python.html still doesn't exist, install a copy from the installation
procedure.
3) Install index.html (the base of the VPython documentation, with link to
Python.html), overwriting index.html if necessary.
4) Specify in the installer that Doc\index.html and Doc\Python.html are not
to be removed by the VPython uninstaller.
I've tested this scheme to some extent, but I'm worried that I might have a
logical flaw somewhere. It does seem robust to multiple installs and
uninstalls of VPython. The only problem I've found with it is that if there
is no Doc\index.html, you get an error message, but if you choose "skip"
(rather than aborting the installation) both index.html and Python.html are
installed correctly. However, if there is no index.html, there are other
things wrong anyway, so maybe this isn't terrible (or maybe I can find a
way to have the installer not issue a warning in this case).
Bruce Sherwood