Where should I put my own python module so that it can be imported
I have my own package in python and I am using it very often. what is the most elegant or conventional directory where i should put my package so it is going to be imported without playing with PYTHONPATH or sys.path?
What about site-packages for example?
Is it common in python to copy and paste the package there ?
I usually put the stuff i want to have ready to import in the user site directory:
To show the right directory for your platform, you can use
python -m site --user-site
edit: it will show up in
sys.path once you create it:
mkdir -p "`python -m site --user-site`"