我想在我的 ubuntu 机器上运行用 python 编写的第三方工具(corgy 工具)。
但是我不知道如何将其他模块添加到 Python 路径。
cat doc/download.rst
There is currently no setup.py, so you need to manually add
the download directory to your PYTHON_PATH environment variable.
如何将目录添加到 PYTHON_PATH?
我试过了:
export PYTHON_PATH=/home/user/directory:$PYTHON_PATH && source .bashrc
export PATH=/home/user/directory:$PATH && source .bashrc
python
import sys
sys.path.append("/home/user/directory/")
但是当我尝试运行这个工具时,我得到:
Traceback (most recent call last):
File "examples/dotbracket_to_bulge_graph.py", line 4, in <module>
import corgy.graph.bulge_graph as cgb
ImportError: No module named corgy.graph.bulge_graph