Allows apps to define management commands that are called from a central management command. Likely scenarios are post-deploy configurations (insert groups/permissions, compilemessages etc.)
- Django >= 1.4
- Management command to run other management commands
- Allows apps to "hook" onto and be run from a central management command
To install django-genesis
simply run:
pip install git+ssh://[email protected]/TwigWorld/[email protected]#egg=django-genesis==1.0.0
We need to hook django-genesis
into our project.
Put
genesis
into yourINSTALLED_APPS
at settings module:INSTALLED_APPS = ( ... 'genesis', )
After installation we can finally use genesis.
Let's get started quickly. Running this line:
python manage.py let_there_be_light
On an example django project with the below installed apps:
app_1/ management/ commands/ __init__.py app_1_bootstrap.py other_stuff.py app_2/ management/ commands/ __init__.py app_2_bootstrap.py a_new_stuff.py app_3/ management/ commands/ __init__.py another_new_stuff.py
Will cause the following management commands to be run:
app_1_bootstrap.py app_2_bootstrap.py
All management commands to be run from let_there_be_light
MUST be named {app_name}_bootstrap.py