virtualenv env
pip install -e git+https://github.com/pinard/Pymacs.git@v0.24-beta2#egg=Pymacs-dev
pip install -e hg+https://bitbucket.org/agr/rope#egg=rope-dev
pip install -e hg+https://bitbucket.org/agr/ropemacs#egg=ropemacs-trunk
pip install -e hg+https://bitbucket.org/agr/ropemode#egg=ropemode-trunk
cd env/src/pymacs
make install
将以下内容添加到 .emacs (setq virtual-env (getenv "VIRTUAL_ENV")) (setq load-path (append (list (concat virtual-env "/src/pymacs" )) load-path))
(if (not (equal virtual-env 'nil))
(let ((foo 'bar))
(require 'pymacs)
(pymacs-load "ropemacs" "rope-")
(setq ropemacs-enable-autoimport 't)
(setq ropemacs-autoimport-modules '("os" "shutil"))
))
之后,我可以获得完整的代码、文档、定义。
但是,输入rmtree,执行rope-auto-imoport后,“from shutil import rmtree”没有出现。
相反,我收到消息“未找到全局名称 rmtree! ”
帮我!
我已经尝试了 config.py 并添加了 extension_modules 和 python_path。