README
1This is versioncheck 1.0, a first stab at automatic checking of versions of
2Python extension packages installed on your system.
3
4The basic idea is that each package contains a _checkversion.py
5somewhere, probably at the root level of the package. In addition, each
6package maintainer makes a file available on the net, through ftp or
7http, which contains the version number of the most recent distribution
8and some readable text explaining the differences with previous
9versions, where to download the package, etc.
10
11The checkversions.py script walks through the installed Python tree (or
12through a tree of choice), and runs each _checkversion.py script. These
13scripts retrieve the current-version file over the net, compares version
14numbers and tells the user about new versions of packages available.
15
16A boilerplate for the _checkversion.py file can be found here. Replace
17package name, version and the URL of the version-check file and put it in
18your distribution. In stead of a single URL you can also specify a list
19of URLs. Each of these will be checked in order until one is available,
20this is handy for distributions that live in multiple places. Put the
21primary distribution site (the most up-to-date site) before others.
22The script is executed with execfile(), not imported, and the current
23directory is the checkversion directory, so be careful with globals,
24importing, etc.
25
26The version-check file consists of an rfc822-style header followed by
27plaintext. The only header field checked currently is
28'Current-Version:', which should contain te current version and is
29matched against the string contained in the _checkversion.py script.
30The rest of the file is human-readable text and presented to the user if
31there is a version mismatch. It should contain at the very least a URL
32of either the current distribution or a webpage describing it.
33
34Pycheckversion.py is the module that does the actual checking of versions.
35It should be fine where it is, it is imported by checkversion before anything
36else is done, but if imports fail you may want to move it to somewhere
37along sys.path.
38
39 Jack Jansen, CWI, 23-Dec-97.
40 <jack@cwi.nl>
41
42