Start Application¶
Usage: start-app APP_NAME [-h] [--completion COMPLETION]
Initialize a new django app the falco way.
Arguments
APP_NAME Name of the app to create.
Help
[-h, --help] Show this message and exit.
[--completion COMPLETION] Use --completion generate to print shell-specific completion source. Valid options: generate, complete.
This command executes Django’s startapp
, along with a few additional tasks:
It deletes the
tests.py
file. I never use a single test file when writing tests.It moves the newly created app to the
apps_dir
. In the context of Falco projects, theapps_dir
is a subdirectory in your root directory named after your project.It registers the new app in your settings under
INSTALLED_APP
.It add a basic empty model to your
models.py
file.
These are tasks I always perform when generating a new app with Django. Now, I can reclaim those precious seconds I would have spent doing this manually.