Skip to content

lukasgarcya/cookiecutter-django-magic-content

 
 

Repository files navigation

cookiecutter-django-magic-content

A cookiecutter template for Django using django-magic-content

Description

A basic version of of the Daniel Greenfeld's cookiecutter-django.

It'll create a working django project structure (like when you use the startproject)

It uses the django 1.7 and all the django-magic-content dependecies

Pre Requirements

  • Virtualenv (create isolated environment) :

    $ sudo apt-get install python-pip
    $ sudo pip install virtualenv
  • Pillow (make possible crop images) :

    $ sudo apt-get install python-dev python-setuptools
    $ sudo apt-get install libtiff4-dev libjpeg8-dev zlib1g-dev libfreetype6-dev liblcms2-dev libwebp-dev tcl8.5-dev tk8.5-dev python-tk
    $ sudo apt-get python-imaging
  • NODE and NPM (install assets from bower) :

    $ curl -sL https://deb.nodesource.com/setup | sudo bash -
    $ sudo apt-get install nodejs
    $ sudo npm install npm -g
    $ npm install -g bower

Usage

First, get cookiecutter installed :

Set up your virtualenv:

$ cd <your-envs-folder>
$ virtualenv  --no-site-packages mysite-env
$ cd mysite-env
$ source bin/activate
$ pip install cookiecutter

Now run it against this repo:

$ cookiecutter  https://github.com/huogerac/cookiecutter-django-magic-content

You'll be prompted for some questions, answer them...

It prompts you for questions. Answer them:

Cloning into 'cookiecutter-django'...

project_name (default is "project_name")? mysite
repo_name (default is "repo_name")? mysite
author_name (default is "Your Name")? <your name>
email (default is "Your email")? <your email>
description (default is "A short description of the project.")? My awesome website
year (default is "Current year")? 2015

Setup :

$ cd mysite/
$ pip install -r requirements/local.txt
$ chmod +x manage.py
$ ./manage.py syncdb
$ ./manage.py migrate
$ ./manage.py bower install
$ ./manage.py generate_colors
$ ./manage.py restore_site --backup-name=personal_website --site-id=1
$ ./manage.py runserver

Finally you can access the localhost:8000 and browser over you new awesome website. You can also login and go back to the localhost:8000 and modify any content, as soon add/change images...

Dependencies

The django-magic-content uses as base architecture:

  • Django
  • django-floppyforms
  • django-ckeditor
  • django-image-cropping

Instead of having a monolitic app, django-magic-content is separated in:

Any Problem?

If you are not sure if this could help your case, drop us a message! It'll be a pleasure help you!

Community

Help us by adding Issues about something that you don't feel it's right

If you don't agree the technology, some feature or the decision we've made, no problem! we're totally open for suggestion!

Contribute, you can help us make the difference.

Keep in touch

We're constantly improving those apps, keep one eye on it.

About

A cookiecutter template for creating Django project using the django-magic-content apps quickly.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • CSS 37.6%
  • Python 28.3%
  • HTML 25.0%
  • JavaScript 9.1%