From d31bcc796e41b0af67294d2f01f9dc600d2cae49 Mon Sep 17 00:00:00 2001 From: Marcus Ottosson Date: Fri, 12 May 2017 05:09:14 +0100 Subject: [PATCH] #97: Add __version__ and __spec__ * Enable support for toml.__version__ * Add __spec__ Include reference to which version of the specification this library currently implements. https://github.com/toml-lang/toml/blob/v0.4.0/README.md --- setup.py | 3 ++- toml.py | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 44fb156..fbd46a7 100644 --- a/setup.py +++ b/setup.py @@ -1,9 +1,10 @@ +import toml from distutils.core import setup with open("README.rst") as readmefile: readme = readmefile.read() setup(name='toml', - version='0.9.2', + version=toml.__version__, description="Python Library for Tom's Obvious, Minimal Language", author="Uiri Noyb", author_email="uiri@xqz.ca", diff --git a/toml.py b/toml.py index e7d2f6b..19bdf3d 100644 --- a/toml.py +++ b/toml.py @@ -4,6 +4,9 @@ import re import datetime import io +__version__ = "0.9.2" +__spec__ = "0.4.0" + class TomlDecodeError(Exception): pass