Mercurial > genshi > genshi-test
changeset 424:d698a5556a55
Set the `__version__` property in `genshi.__init__`; only works with a setuptools install, though. Addresses #103.
author | cmlenz |
---|---|
date | Tue, 20 Mar 2007 18:52:00 +0000 |
parents | 7589a0e51001 |
children | 5b248708bbed |
files | genshi/__init__.py |
diffstat | 1 files changed, 5 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/genshi/__init__.py +++ b/genshi/__init__.py @@ -19,5 +19,10 @@ independently of where or how they are produced. """ +try: + __version__ = __import__('pkg_resources').get_distribution('Genshi').version +except ImportError: + pass + from genshi.core import * from genshi.input import ParseError, XML, HTML