Currently my Django project has a huge readme doc, that any developer, whishing to work on the source, must follow to setup their development environment.
It goes something like this:
Prerequisites:
- Django Css. See Django CSS.
- CleverCSS. See Clever CSS.
- Beautiful Soup. See Beautiful Soup.
- Dateutil. See python-dateutil.
- httplib2 http://code.google.com/p/httplib2/
- python-oauth2 https://github.com/simplegeo/python-oauth2
- python-twitter http://code.google.com/p/python-twitter/
Is there any facility for writting some sort of script that will fetch the dependencies automatically? At least to automate this process partially to something like:
python setup_environment.py
I've looked at setuptools - but it seems to me that it is more for the purpose of installing the app itself onto the system, not fulfilling the developer's requirements for environment setup.
Will pip not do the job?
http://www.pip-installer.org/en/latest/index.html#
You can freeze all requirements on your server to a file (run this on the server):
pip freeze > REQUIREMENTS.txt
and then on your dev environment:
pip install -r ./REQUIREMENTS.txt
to install everything listed in the REQUIREMENTS file.
You should also look at installing virtualenv (and virtualenvwrapper) as well on your development (and production) server
http://iamzed.com/2009/05/07/a-primer-on-virtualenv/
They allow you to set up multiple encapsulated python environments. This means you can have two django apps set up on the same machine, each with different python versions/python applications/django versions.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With