在emacs中使用pdb时如何指定路径? [英] How to specifiy path when using pdb in emacs?

查看:266
本文介绍了在emacs中使用pdb时如何指定路径?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在emacs中使用pdb。我需要将路径更改为 PYTHONPATH = lib 。但是当我键入



运行pdb(像这样):PYTHONPATH = lib pdb ./pychess



Emacs给我一个错误,表示找不到文件PYTHONPATH = lib。在emacs中运行pdb时如何指定路径?在终端PYTHONPATH = lib pdb ./pychess运行正常,但不是在emacs。






哦,我得到它只是键入 PYTHONPATH = lib emacs 在启动emacs时。不确定在启动后改变路径...

解决方案

你可以尝试在emacs中设置环境变量这样

 (setenvPYTHONPATHlib)


I am trying to use pdb in emacs. I need to change path to PYTHONPATH=lib. But when I typed

Run pdb (like this): PYTHONPATH=lib pdb ./pychess.

Emacs gives me an error saying the file PYTHONPATH=lib isn't found. How do I specify path when running pdb in emacs? In terminal PYTHONPATH=lib pdb ./pychess runs fine, but not in emacs.


Oh I got it just type PYTHONPATH=lib emacs when launching emacs. Not sure about changing path after launching though...

解决方案

you can try to set the environment variable with in the emacs (say putting in .emacs or using M-:) like this

(setenv "PYTHONPATH" "lib")

这篇关于在emacs中使用pdb时如何指定路径?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆