Skip to main content

Molo is a set of tools for publishing mobi sites with a community focus.

Project description

Continuous Integration Code Coverage Molo Documentation Pypi Package

Scaffold a site using Molo

Molo is a set of tools for publishing mobi sites with a community focus. It scaffolds a Django application for you with sensible defaults, packages and configuration to help you get going as soon as possible:

The goal of Molo is to provide a solid base of proven, stable packages that help Praekelt Foundation and partners to deliver on project scope:

$ pip install molo.core
$ molo scaffold myapp
$ cd myapp/
$ ./manage.py migrate
$ ./manage.py createsuperuser
$ ./manage.py runserver

Open the sample site in your browser at http://localhost:8000/ and the CMS at http://localhost:8000/admin/.

Scaffolding a site in an existing repository

It’s not always desirable to create a new directory for an application, especially when scaffolding an application for a repository that’s already been created. Specifically for that Molo allows a second argument for the directory.

To scaffold an application called myapp in the current directory do:

$ molo scaffold myapp .

Molo, Django & settings files

What you have now is a standard Django application set up for normal development like outlined in the Django documentation. The only main difference is that your settings are Python modules found in the settings/dev.py and settings/production.py files in your applications folder. Both of these inherit settings from settings/base.py.

To create your own custom settings add a local.py file in the settings folder. The settings/dev.py will automatically include those settings for your local development environment.

Writing tests

Now develop your application and write tests for the features you add. Running your tests for Django works as you would expect:

$ ./manage.py test

What is bundled with Molo?

  1. Basic feature phone template set.

  2. Basic models for the following tree structure:

    1. A site has languages

    2. A language has a homepage

    3. Articles are organised into sections.

    4. Articles are composed from one or more blocks.

    5. Blocks can be headings, paragraphs, images, lists or links to other pages.

Testing the Molo scaffolding tool

If you’re interested in working on or contributing to the code that does the scaffolding then clone this repository from the GitHub repository at http://github.com/praekelt/molo.

Install the requirement development & testing dependencies:

$ pip install -r requirements-dev.txt

And then run the full test suite with:

$ ./run-tests.sh

Pull requests are expected to follow Praekelt’s Ways Of Working.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

molo.core-2.3.6.tar.gz (36.0 kB view details)

Uploaded Source

File details

Details for the file molo.core-2.3.6.tar.gz.

File metadata

  • Download URL: molo.core-2.3.6.tar.gz
  • Upload date:
  • Size: 36.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for molo.core-2.3.6.tar.gz
Algorithm Hash digest
SHA256 1789b5546ea32dc2198046fe816417eccaef30312cd8158b547371f5a64af8dd
MD5 85c4f3cc3f62bdb6e2a4ab1fbc8c603b
BLAKE2b-256 d5722193a6e762bb5a994cce60981406040169bb4f196324570ef3541158b37a

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page