【问题标题】:How to get Aquamacs to run code in ipython如何让 Aquamacs 在 ipython 中运行代码
【发布时间】:2013-12-02 01:44:52
【问题描述】:

我在 OS X lion 上使用 Aquamacs 并尝试使用最新的 python-mode.el 来编辑和运行我的 python 代码。我可以通过键入 C-! 打开 ipython shell,但是如果我运行 C-c C-c 或 C-c | python 代码在没有 ipython 的新 Python 缓冲区中运行。我已经尝试了许多修复。以下是我的 .emacs 文件中特定于 python 的部分:

(when (featurep 'python) (unload-feature 'python t))
;; add custom libs
(add-to-list 'load-path "~/tools/emacs")
;; Set up pylab 
(setq py-install-directory "/Users/stringham/tools/emacs/")
(require 'python-mode)
(setq py-shell-name "/usr/local/bin/ipython")
(setq py-python-command "/usr/local/bin/ipython")

有没有人成功地将 ipython 与 Aquamacs 结合使用?

【问题讨论】:

    标签: python emacs ipython aquamacs python-mode


    【解决方案1】:

    Shebang 将优先于默认设置。 要覆盖 shebang,请使用例如 M-x py-execute-buffer-ipython RET

    提交了修复。请在

    查看当前主干

    https://launchpad.net/python-mode

    通过集市:

    bzr branch lp:python-mode
    

    或从您的浏览器下载。

    【讨论】:

      猜你喜欢
      • 2018-11-15
      • 1970-01-01
      • 2013-12-20
      • 2018-12-23
      • 1970-01-01
      • 2021-11-09
      • 2014-08-11
      • 2020-03-06
      • 2018-07-26
      相关资源
      最近更新 更多