Last active
January 30, 2020 16:16
-
-
Save dmgl/b07122d8aa5f3c538b7d to your computer and use it in GitHub Desktop.
How to launch Idle from virtualenv
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from idlelib.PyShell import main | |
if __name__ == '__main__': | |
main() | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# This hook is run after a new virtualenv is created and before it is activated. | |
# argument: name of new environment | |
cp /path_to_idle/idle.py $1/bin/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# after command $ source bin/activate in ENV | |
(ENV)user@system:~/pathtoenv$ cd bin/ | |
# copy idle.py to virtualenv bin/ path, pun | |
(ENV)user@system:~/pathtoenv$ idle.py | |
# or use premkvirtualenv file with virtualenvwrapper | |
# no need to copy idle.py each time before make env |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
for some reason, after creating a venv with
python3 -m venv /dir/that/iwant/specificproject/
, then sourcing the venv, and trying to runpython -m idlelib
gives me this error:/home/dps/.venv/testing/bin/python: No module named idlelib
im new to this, so that could be whats wrong lol.
and i dont know if this was the right place to put this, i just came across this github page from a google search looking for an answer to my issue