Commit e7c48cc1 authored by Manuel Günther's avatar Manuel Günther
Browse files

Added get_config().

parent 668662b3
......@@ -27,6 +27,21 @@
from .models import File, Client
from .query import Database
__all__ = dir()
def get_config():
"""Returns a string containing the configuration information.
import pkg_resources
packages = pkg_resources.require(__name__)
this = packages[0]
deps = packages[1:]
retval = "%s: %s (%s)\n" % (this.key, this.version, this.location)
retval += " - python dependencies:\n"
for d in deps: retval += " - %s: %s (%s)\n" % (d.key, d.version, d.location)
return retval.strip()
# gets sphinx autodoc done right - don't remove it
__all__ = [_ for _ in dir() if not _.startswith('_')]
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment