This project is still in it's early stages, so if you come across something that is broken, please let me know. Patches, improvements and other feedback is most welcome.
This project allows you to easily start a Django project based on the amazing HTML5 Boilerplate template and build system (http://html5boilerplate.com/).
The django-html5-boilerplate project initially only contains two Python scripts
which are described below. These scripts will be available on your virtualenv's
path if you install via
python setup.py install or
pip install <package>.
- Python 2.x
- Java JRE or JDK
- Ant (1.8.2)
- (Django and HTML5 Boilerplate will be downloaded when
This is equivalent to Django's
django-admin.py startproject command so use it
with your intended project name as an argument to begin your project. You are
advised to start off in a clean virtualenv with no Django project created yet.
Read more about virtualenv and virtualenvwrapper at
- Downloads Django if necessary
- Makes a new Django project with the name of your choice using
- Downloads HTML5 Boilerplate and extracts it
- Moves HTML5 Boilerplate HTML, CSS and images into your new project under templates and static directories
- Sets up the HTML5 Boilerplate installation to build from your Django project
This is run when you are about to deploy to a server. This may take a minute or
more to run as it is using html5boilerplate's Ant build optimisations. When
buildproject has run, the optimised version of static is in a separtate
directory called static_publish and the same goes for templates. Running
your server in production mode with
DEBUG=False will cause the optimised
templates to be used by and you should configure your webserver to serve
static_published at the /static/ URL. The build process uses staticfiles
which is new in Django 1.3. This should mean that static content from
INSTALLED_APPS should also get collected together and optimised. If you're
wondering why static is not called media, Django now recommends media is
just used for user-uploaded content. Read more here:
- Moves the compressed output files into static_publish and templates_publish.
their original location for future editing and still used when