diff options
author | Olivier Tilloy <olivier@tilloy.net> | 2010-01-21 22:04:00 +0100 |
---|---|---|
committer | Olivier Tilloy <olivier@tilloy.net> | 2010-01-21 22:04:00 +0100 |
commit | c5cf46e198cbd3f77c7af8cc1a56c0140578cbae (patch) | |
tree | f92c7125c6403ab89a947bae15b99dba4bc9b065 /src | |
parent | b23f34c6b618e2af51757f758673920e916a4041 (diff) | |
download | pyexiv2-c5cf46e198cbd3f77c7af8cc1a56c0140578cbae.tar.gz |
Standard version_info and __version__ attributes
+ exiv2_version_info and __exiv2_version__.
Set version_info to (0, 2, 0), ready for the next release.
Diffstat (limited to 'src')
-rw-r--r-- | src/exiv2wrapper_python.cpp | 2 | ||||
-rw-r--r-- | src/pyexiv2/__init__.py | 10 |
2 files changed, 9 insertions, 3 deletions
diff --git a/src/exiv2wrapper_python.cpp b/src/exiv2wrapper_python.cpp index 694416d..717b0b4 100644 --- a/src/exiv2wrapper_python.cpp +++ b/src/exiv2wrapper_python.cpp @@ -41,7 +41,7 @@ boost::python::tuple exiv2_version = \ BOOST_PYTHON_MODULE(libexiv2python) { - scope().attr("__exiv2_version__") = exiv2_version; + scope().attr("exiv2_version_info") = exiv2_version; register_exception_translator<Exiv2::Error>(&translateExiv2Error); diff --git a/src/pyexiv2/__init__.py b/src/pyexiv2/__init__.py index 4b83d54..91ce1b5 100644 --- a/src/pyexiv2/__init__.py +++ b/src/pyexiv2/__init__.py @@ -68,7 +68,13 @@ from pyexiv2.utils import FixedOffset, Rational, NotifyingList, \ GPSCoordinate -__version__ = (0, 2, 1) +def _make_version(version_info): + return '.'.join([str(i) for i in version_info]) -__exiv2_version__ = libexiv2python.__exiv2_version__ + +version_info = (0, 2, 0) +__version__ = _make_version(version_info) + +exiv2_version_info = libexiv2python.exiv2_version_info +__exiv2_version__ = _make_version(exiv2_version_info) |