Scribe is a web-based story writing and sharing platform built with Flask. It allows users to create accounts, write stories, and share them with others.
- User authentication (register, login, logout)
- Create and publish stories
- View stories from all users
- Secure password hashing
- PostgreSQL database integration
- Docker support for easy deployment
- Download stories as PDF or EPUB
- Chapter support for stories & story editing
- Tags (up to 10 per story)
- Search and Advanced search
- Search by title:
title:"your title" - Search by author:
by:"author name" - Search by tags:
tags:"tag1, tag2" - Combine search modifiers:
title:"title1" by:"user1" tags:"fantasy, adventure"
- Search by title:
- User Profiles and Statistics
- Story Ratings
- Story Covers
- Search Filters
- "Uploaded" and "Last Updated" dates
- User Library and Story Saving
- Pagination (we no longer load more than 20 stories on homepage at a time (10 for user pages))
- Unit tests
- Python 3.7+
- Docker and Docker Compose (for containerized deployment)
- PostgreSQL (if running without Docker)
- Clone the repository:
git clone <repository-url>
cd scribe- Start the application using Docker Compose:
docker-compose up --buildThe application will be available at http://localhost:5000
- Clone the repository:
git clone <repository-url>
cd scribe- Create a virtual environment and activate it:
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate- Install dependencies:
pip install -r requirements.txt- Set up environment variables:
export SECRET_KEY='your-secret-key'
export DATABASE_URL='postgresql://username:password@localhost:5432/scribe'- Run the database migration:
flask db upgrade- Run the application:
python app.pyscribe/
├── app.py # Main application file
├── requirements.txt # Python dependencies
├── api_documentation.json # API documentation (for Postman/Insomnia)
├── Dockerfile # Docker configuration
├── docker-compose.yml # Docker Compose configuration
├── app/ # Most functionality implementations
├── tests/ # Pytest unit tests
├── templates/ # HTML templates
└── migrations/ # Database migrations
- Flask - Web framework
- Flask-SQLAlchemy - Database ORM
- Flask-Login - User authentication
- Flask-WTF - Form handling
- psycopg2-binary - PostgreSQL adapter
- python-dotenv - Environment variable management
- Werkzeug - WSGI utilities
- SQLAlchemy - SQL toolkit
- Pytest - Testing