问题描述
我试图设置ipython默认文本编辑器。使用Ipython 0.13.2使用%edit magic我收到以下消息:
Am trying to set ipython default text editor. Using Ipython 0.13.2 Using the %edit magic I get the following message:
No default editor available.
Specify a GUI text editor in the `IPythonWidget.editor` configurable to enable the %edit magic
tried looking for it in IPython tried importing IPythonWidget.. no luck
检查了以下问题:
还检查了Ipython配置系统概述。
我可以创建配置文件(使用ipython命令行选项),我知道他们在启动时添加了启动文件的位置文件夹。
I can create profiles (using the ipython command line options) and I know where they are have added started files to the startup folder in the config directory.
我没有按照配置类的工作原理。看起来我必须创建它们?我应该将它们保存在我的ipython配置启动文件夹中吗?
I don't follow how the Configuration classes work at all. Looks like I have to create them? Should I save them in my ipython configuration startup folder?
特别想要将Sublime Text设置为编辑器,但如果我可以获得任何编辑器的说明,可能会调整它的形式那里。
Specifically looking to set Sublime Text as editor, but if I can get instructions on any editor, can probably adapt it form there.
推荐答案
在你的个人资料中,编辑 ipython_qtconsole_config.py
,你找到一行#c.IPythonWidget.editor =''
取消注释并将值设置为启动编辑器的命令。
In your profile, edit ipython_qtconsole_config.py
, you'll find a line # c.IPythonWidget.editor = ''
uncomment and set the value to the command to launch your editor.
这篇关于IPython设置文本编辑器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!