I'm using win7, python 2.7 and I have a project with several packages running.
I wanted to move the project to my friends laptop (which can't access to internet, not an option). so I downloaded Python/Django/All required packages, Installed python and run python setup.py install
in each package directory.
I've found that some packages, even after I download them, requires somethings from the internet to be downloaded and causes error. so:
How can I download a package and all it's dependencies or what ever it needs to be installed offline?
This is how you can do it
Install Django and all related packages to a Python virtual environment
Run
pip freeze > requirements.txt
which will list all installed packages and their versions in this fileUse
pip wheel -r requirements.txt
command which builds awheelhouse
folder of the package listZip this folder
Go to your friend's computer, unzip
create virtual environment and run
pip install wheelhouse/*
(Install all packages from the wheelhouse)More about pip wheel.
Python and pip needs to be separately copied and installed.