2013-10-30 2 views
0

저는 vim, mac os x, virtualenv, zsh를 사용하여 파이썬을 개발합니다.vim에서 명령을 실행할 수 없지만 쉘에서 실행할 수 있습니까?

하지만 가상의 환경을 만들고 pip install fabric과 함께 python 패키지를 설치하고 명령 행에서 fab을 실행 한 후에 아주 이상한 것을 발견했습니다. 잘 작동한다. 나는 그것이 어떤 python path 변수가 재설정 된 내가 정력을 열 때 발생 된 생각, 그래서이를 찾을 수 없습니다

Traceback (most recent call last):             │ * Restarting with reloader 
    File "/usr/local/bin/fab", line 5, in <module>         │ * Detected change in '/Users/ccheng/workspace/rms-rest/rms/account.py', reloading 
    from pkg_resources import load_entry_point          │ * Restarting with reloader 
    File "build/bdist.macosx-10.9-intel/egg/pkg_resources.py", line 2793, in <module> │ * Detected change in '/Users/ccheng/workspace/rms-rest/rms/account.py', reloading 
                        │ * Restarting with reloader 
    File "build/bdist.macosx-10.9-intel/egg/pkg_resources.py", line 673, in require │ * Detected change in '/Users/ccheng/workspace/rms-rest/rms/rms.py', reloading 
    def subscribe(self, callback):             │ * Restarting with reloader 
    File "build/bdist.macosx-10.9-intel/egg/pkg_resources.py", line 576, in resolve │ * Detected change in '/Users/ccheng/workspace/rms-rest/rms/rms.py', reloading 
    plugin_env, full_env=None, installer=None, fallback=True      │ * Restarting with reloader 
pkg_resources.DistributionNotFound: Fabric==1.8.0         │ * Detected change in 'run.py', reloading 
                        │ * Restarting with reloader 
shell returned 1 

:
그런 다음 내가 정력을 열고 :!fabfab을 실행, 그것은 나에게 다음과 같은 오류를 제공 패키지는 virtualenv에 설치됩니다.

+2

vim 셸에서 다시 '소스 bin/활성화'했습니까? – moofins

+0

'echo $ PATH'와':! echo $ PATH'의 각각의 결과는 무엇입니까? 그래도 자신의 질문에 대답 한 것처럼 들리네. 경로 문제 – aychedee

+0

@moofins 그것은 vim shell에서 다시 소스 할 필요가없는 것 같습니다. –

답변

0

터미널 구성에서 기본 셸을 설정하여이 문제를 해결합니다. 나는 이것이 'chsh'를 사용하는 기본 쉘 설정과 다른 점을 알지 못하지만 작동합니다. 모두에게 감사드립니다.

관련 문제