Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Offtopic: with all these ipython/bpython's only thing that bugs me is need to do pip install -U ipython bpython (which downloads significant portion of bytes) in every virtualenv. I wonder if there's something like "pip install -U ipython --local-cache" option to copy existing ipython inside this virtualenv.


If you simply wish to access a virtualenv from your system ipython, you could do:

    with open('path/to/venv/bin/activate_this.py') as fh:
        exec(fh.read(), {'__file__' : fh.name})
Actually, having a %workon magic command for virtualenvwrapper[1] users seems like a useful thing. I think I'll write that ...

[1] http://pypi.python.org/pypi/virtualenvwrapper



Wow, thanks a lot! I wonder why it's not in default somewhere.


virtualenvwrapper has scripts that run after certain operations e.g. creating a virtualenv. I use this to install bpython, sphinx and tox into every new virtualenv.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: