Installation#

Django Literature is two apps that ship together. The core, literature, holds the models and the converters and pulls in no web interface. This page installs the core. The web interface, literature.ui, adds the catalogue and its pages, and is installed on top of it as described in Installing the web interface.

The core needs Python 3.12 or later and Django 5.2 or later.

Steps#

  1. Install the package:

    pip install django-literature
    

    django-partial-dates, which stores dates at the precision they are known, is installed with it.

  2. Add literature to INSTALLED_APPS:

    # settings.py
    INSTALLED_APPS = [
        # ...
        "literature",
    ]
    
  3. Apply the migrations:

    python manage.py migrate
    

The database now has one table for each model in the data model:

Table

Django model

literature_item

Item

literature_name

Name

literature_itemname

ItemName

literature_itemdate

ItemDate

literature_itemidentifier

ItemIdentifier

A database that still holds the old LiteratureItem tables is moved over as described in Upgrading from the LiteratureItem schema instead.