From: Georg Brandl Date: Sun, 2 Mar 2008 06:44:08 +0000 (+0000) Subject: Make patchlevel print out the release if called as a script. X-Git-Tag: v2.6a2~434 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f0177282199d4b19108210a357f726a26c05afe1;p=python Make patchlevel print out the release if called as a script. --- diff --git a/Doc/tools/sphinxext/patchlevel.py b/Doc/tools/sphinxext/patchlevel.py index 971ea6197f..cb9e35c226 100644 --- a/Doc/tools/sphinxext/patchlevel.py +++ b/Doc/tools/sphinxext/patchlevel.py @@ -66,3 +66,6 @@ def get_version_info(): print >>sys.stderr, 'Can\'t get version info from Include/patchlevel.h, ' \ 'using version of this interpreter (%s).' % release return version, release + +if __name__ == '__main__': + print get_header_version_info('.')[1]