resourcer

来自「minimal python variant for small footpri」· 代码 · 共 52 行

TXT
52
字号
#!/usr/bin/env python# Only the supplied Python-1.5.2+ (pre-unicode tag in the Python CVS# repository).import syserror_string = """ERROR:	Invalid Python version	Python 1.5.2+ required	(see pre-unicode tag in CVS repository)"""def exit():	print error_string	sys.exit()# first, check for string methodstry:	"ab".split()except AttributeError:	exit()# check the revision stringif sys.version[:6] != '1.5.2+':	exit()# be sure that unicode is not presentimport exceptionsif hasattr(exceptions, 'UnicodeError'):	exit()# be sure that the PYTHONPATH points to our modified librarytry:	exceptions.MissingFeatureErrorexcept AttributeError:	print """ERROR:	The path to the standard Python library must be	the one supplied with the Pippy distribution.  Prepend either	PYTHONPATH or sys.path with the correct path."""	sys.exit()if __name__ == '__main__':	import Resourcer.resourcer	Resourcer.resourcer.main()

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?