sublime怎么用?sublime text3怎么配置sublimerepl快捷键?下面就给大家介绍其修改方法,希望对需要的朋友有所帮助!
因为用sublime运行python,如果有input()函数,ctrl+b是不能输入数据的,所以下载安装了sublimerepl进行调试。
但是sublimerepl没有自定义快捷键,所以只有自己设置。
网上很多方法但是都没有效果,最后折腾了一晚上终于找到正确方式。
首先找到sublimerepl的配置文件。
步骤:preferences-->browse packages-->sublimerepl文件夹-->config文件夹-->python文件夹-->default.sublime-commands(以文本格式打开)
[ { "caption": "sublimerepl: python", "command": "run_existing_window_command", "args": { "id": "repl_python", "file": "config/python/main.sublime-menu" } }, { "caption": "sublimerepl: python - pdb current file", "command": "run_existing_window_command", "args": { "id": "repl_python_pdb", "file": "config/python/main.sublime-menu" } }, { "caption": "sublimerepl: python - run current file", "command": "run_existing_window_command", "args": { "id": "repl_python_run", "file": "config/python/main.sublime-menu" } }, { "command": "python_virtualenv_repl", "caption": "sublimerepl: python - virtualenv" }, { "caption": "sublimerepl: python - ipython", "command": "run_existing_window_command", "args": { "id": "repl_python_ipython", "file": "config/python/main.sublime-menu" } }]
这是repl的配置文件,找到你需要的命令复制下来。
粘贴到preferences-->key bindings user
代码如下
[ { "keys": ["f5"],//这是自己设的快捷键 “” "command": "run_existing_window_command", "args": { "id": "repl_python_run", "file": "config/python/main.sublime-menu" } }]
最后保存就行了。
如图
关于sublime 每次打开更新的提示
preferences->seting user -》{"font_size": 13,"update_check":false,}
更多sublime相关技术文章,请访问sublime栏目.
以上就是sublime text3配置sublimerepl快捷键的方法(python)的详细内容。