*fix: get python version properly
This commit is contained in:
@@ -43,9 +43,14 @@ def curKERNEL():
|
|||||||
versionString = file("/proc/version").readline()
|
versionString = file("/proc/version").readline()
|
||||||
return versionString.split()[2]
|
return versionString.split()[2]
|
||||||
|
|
||||||
|
#FIXME: misleading name, what does this mean?
|
||||||
|
#we want the "pythonlibdir"
|
||||||
def curPYTHON():
|
def curPYTHON():
|
||||||
''' returns currently used python's version'''
|
''' returns currently used python's version'''
|
||||||
return os.path.basename(os.readlink("/usr/bin/python"))
|
# the method of reading symlink name was totally lame :) -- exa
|
||||||
|
import sys
|
||||||
|
(a, b, c, x, y) = sys.version_info
|
||||||
|
return 'python%s.%s' % (a, b)
|
||||||
|
|
||||||
def ENV(environ):
|
def ENV(environ):
|
||||||
'''returns any given environ variable'''
|
'''returns any given environ variable'''
|
||||||
|
|||||||
Reference in New Issue
Block a user