Skip to content

Instantly share code, notes, and snippets.

@jasjukaitis
Last active October 7, 2015 11:08
Show Gist options
  • Save jasjukaitis/3155888 to your computer and use it in GitHub Desktop.
Save jasjukaitis/3155888 to your computer and use it in GitHub Desktop.
Creates a new Django project using my boilerplate
#!/bin/sh
# Creates a new Django project using my boilerplate
# Requires virtualenvwrapper and pip
source virtualenvwrapper.sh
# Create a new virtualenv if none other is active
if [ "$VIRTUAL_ENV" == "" ]; then
echo "Creating virtualenv... Name?"
read venvname
mkvirtualenv --no-site-packages $venvname
workon $venvname
else echo "Using active virtualenv."
fi
pip install django fabric
source django-admin.py
echo "Name of the project?"
read projectname
django-admin.py startproject --template=https://github.com/raphaa/django-cms-boilerplate/zipball/master $projectname
cd $projectname
chmod +x manage.py
fab init_project
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment