astdump 0.5
Extract information from Python module without importing it.
Latest Version: 1.0
Fetch module version without executing the module. Generates setup.py using information from the module. Can become handy for distutils.
$ ./astdump.py Usage: astdump.py [options] <filename.py> Read top level variables from the module without importing it. Additional keys allow to generate setup.py automatically or view tree structure of an Abstract Syntax Tree. Options: -h, --help show this help message and exit --dump dump abstract syntax tree --generate generate setup.py for a given filename
Examples:
$ ./astdump.py astdump.py __author__ = 'anatoly techtonik <techtonik@gmail.com>' __description__ = 'Extract information from Python module without importing it.' __license__ = 'Public Domain' __version__ = '0.5'
$ ./astdump.py astdump.py --generate #!/usr/bin/env python from distutils.core import setup setup( name = 'astdump', version = '0.5', author = 'anatoly techtonik', author_email = 'techtonik@gmail.com', description = 'Extract information from Python module without importing it.', license = 'Public Domain', py_modules=['astdump'], )
| File | Type | Py Version | Uploaded on | Size | # downloads |
|---|---|---|---|---|---|
| astdump-0.5.tar.gz (md5) | Source | 2012-02-02 | 2KB | 191 | |
- Author: anatoly techtonik
- Home Page: https://bitbucket.org/techtonik/astdump
- License: Public Domain
- Categories
- Package Index Owner: techtonik
- DOAP record: astdump-0.5.xml
