本文共 308 字,大约阅读时间需要 1 分钟。
#!/usr/bin/env python
import sys
import readlineimport rlcompleterif sys.platform == 'darwin' and sys.version_info[0] == 2:
readline.parse_and_bind("bind ^I rl_complete")else:readline.parse_and_bind("tab: complete") # linux and python3 on mac转载于:https://blog.51cto.com/yeqing/2050780