mirror of
https://github.com/python/cpython.git
synced 2025-09-26 18:29:57 +00:00
Make patchlevel print out the release if called as a script.
This commit is contained in:
parent
7f7e30ae2e
commit
f017728219
1 changed files with 3 additions and 0 deletions
|
@ -66,3 +66,6 @@ def get_version_info():
|
||||||
print >>sys.stderr, 'Can\'t get version info from Include/patchlevel.h, ' \
|
print >>sys.stderr, 'Can\'t get version info from Include/patchlevel.h, ' \
|
||||||
'using version of this interpreter (%s).' % release
|
'using version of this interpreter (%s).' % release
|
||||||
return version, release
|
return version, release
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
print get_header_version_info('.')[1]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue