Commit ceeec381 authored by Pranav Jerry's avatar Pranav Jerry

added a model Story and polished IDEAS.md

taleverse is in pre-alpha stage so it is not fit for production use

I've added a brain dump to IDEAS.md
parent c3433853
......@@ -2,8 +2,27 @@
This file is a blueprint of Taleverse.
So this is what it should do:
## Tale
A tale is a story filling utmost 4 pages.
In a model, Tale should have the following attributes:
- uuid: string, primary key (eg: `2bec724e-36c3-4149-a9b1-44257400b470`)
- title: string (eg: `The Fox and the GNU`)
- license: string, any of `CC-BY-4.0`, `CC-BY-SA-4.0`, `CC0-1.0`
- language: two-letter string (eg: `en`)
- other_languages: tuple for mentioning other languages reffering to other
versions. For example:
```json
{
"ml": "6c65e8b8-329e-4129-8dd9-b00998d3161c",
"de": "21c64fde-7002-4ca7-9cf4-1efe629c868e"
}
```
- authors: reference to user model (to be created)
## Notes
- users should be able to create stories
- stories can have translations in multiple languages
- users can edit other user's stories
- the server should support federation (is ActivityPub enough?)
- users can edit other user's stories (like MediaWiki)
- the server should support federation (ActivityPub, anyone?)
......@@ -12,21 +12,22 @@ setup(
version='0.0.1',
packages=find_packages(),
include_package_data=True,
license='AGPL 3.0', # example license
license='AGPL 3.0',
description='A Django app to read and create stories',
long_description=README,
url='https://git.fsci.org.in/inator/taleverse',
url='https://git.fsci.org.in/inator/django-taleverse',
author='Pranav Jerry',
author_email='libreinator@disroot.org',
classifiers=[
'Environment :: Web Environment',
'Framework :: Django',
'Intended Audience :: Developers',
'License :: OSI Approved :: AGPL 3.0', # example license
'License :: OSI Approved :: AGPL 3.0',
'Operating System :: OS Independent',
'Programming Language :: Python',
'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Topic :: Internet :: WWW/HTTP',
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
],
......
from django.contrib import admin
from .models import Story
# Register your models here.
admin.site.register(Story)
from django.db import models
from django.conf import settings
from uuid import uuid4
# Create your models here.
class Story(models.Model):
uuid = models.CharField(max_length=36, primary_key=True, default=uuid4,
editable=False)
title = models.CharField(max_length=50)
language = models.CharField(max_length=7, choices=settings.LANGUAGES)
def __str__(self):
return self.title
# Metadata
class Meta:
ordering = ['title']
verbose_name_plural = "Stories"
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment