tha.taglist generates an html list of svn tags suitable for
This package was originally developed for The Health Agency. We’re now using an alternative: generate
the sdist eggs into a pypi-like structure. See tha.sdistmaker
Installation is the normal buildout procedure.
Some functionality from older versions (the actual finding of tags in svn) was
splitted out into a separate library, tha.tagfinder.
How it works
The script iterates over the BASE repository as defined in
tha/taglist/defaults.py. It first tries to use BASE_ON_SERVER,
which you can use to define file:///svn as an alternative base
when available, which speeds it up on the server and which also makes
it usable for every user account. It has a blacklist of directories
it won’t interate into. Every directory is examined for “stop
indicators” like setup.py that indicate that there aren’t any
useful tag directories further down. See defaults.py for documentation
on how to override it in your buildout.
If a tags/ directory is found an entry in the packages.html is
The tag (‘1.0’). We do a regex search for the version in the
setup.py. If found and if it doesn’t match the tag, we emit a
The svn url.
The name that is extracted (with a regex) from the setup.py.
You can start the script with ‘-v’ or ‘-vv’ for more verbose logging.
Documentation update: pointing at tha.sdistmaker as alternative. And
cleaned up license, email address etc.
Re-added BASE_ON_SERVER to BASE url rewriting of found tag urls. [reinout]
Fixed BASE/BASE_ON_SERVER bug. [reinout]
Factored out tag finding code into tha.tagfinder. [reinout]
Writing to tempfile again and shutil.move()-ing it in place. See if that
helps with file permissions. Writing directly gave me permission errors in
the post-commit hook that I didn’t get with the tempfile still enabled.
Generating page with a jinja template now. Instead of yucky string
Fix for 0.8: filtering out non-numeric versions for the list of latest
Added listing of latest versions to the bottom of the page. [reinout]
Small bugfix (reported by Maurits): use shutil.move instead of os.rename as
the latter doesn’t work between two filesystems. [reinout]
Doc update. [reinout]
Configuration is now done through a defaults file that can be
overridden by a buildout option. [reinout]
Added generation date to the top of the generated html file.
Quieted down logging to only emit warnings. Added -v and –v options
for info/debug level logging. [reinout]
Added check (regex-based) whether the version in setup.py matches
the tag. If not, it emits a warning. [reinout]
Make destination configurable.
Using file:///svn on server (with non-server fallback to
Added buildout.cfg. [reinout]
Tags are searched in the entire tree (excluding blacklisted items).
The html gets written to generated.html. [reinout]
Extracting name from setup.py with a regular expression. [reinout]
Option: check the name and version for each tagged package by
finding the setup.py, running it and asking for its name and
version instead of doing a regex search. For this you need a full
checkout of the whole repository instead of just a temporary
checkout of a setup.py file.