def _parse(self, parser):
options, args = parser.parse_args()
if not options.allow_root and self._is_root():
parser.error(
"running as root - " +
"run as a different user or specify the --allow-root " +
"command line option")
if options.python is not None:
os.execlp(options.python, options.python, sys.argv[0], *args)
if sys.version_info < (2, 6):
version = platform.python_version()
parser.error(
"this tool requires python >= 2.6 " +
"(you are running python " + version + "), " +
"use the option -p/--python to define a suitable python " +
"executable")
return options, args
评论列表
文章目录