Skip to main content

A tiny tool to present and manage your reading and notes.

Project description

Paperead

Downloads

Paperead A tiny tool to present and manage your reading and notes.

  • Platform
  • Python

Install

Use pip:

pip install paperead

Or use pipx:

# Install pipx
pip install --user pipx
pipx ensurepath

# Install Schemdule
pipx install paperead

# Upgrade
pipx upgrade paperead

Usage

Command-line Management

Create/Delete/List materials and notes.

# Use current directory as data directory
paperead new/rm/list --help

# Custom data directory
paperead -D "path/to/dataDir" <COMMANDS>

Website Server

paperead serve

paperead -D "path/to/dataDir" serve

Then visit http://localhost:3649.

RESTful APIs:

  • /api/materials/
    • GET: Get all ids for materials
    • POST: Create or update a material
  • /api/materials/<id>
    • GET: Get data of the material
    • DELETE: Delete the material
  • /api/materials/<id>/assets/<path>
    • GET: Access assets of the material
  • /api/materials/<id>/notes/
    • GET: Get all ids for notes of the material
    • POST: Create or update a note of the material
  • /api/materials/<id>/notes/<nid>
    • GET: Get data of the note of the material
    • DELETE: Delete the note of the material

Data Directory

Paperead works in a data directory. The directory's structure is like the following.

/
    material1/
        description.md
        assets/
        notes/
            note1.md

Material Description

<material>/description.md contains the metadata and the description for the material.

---
# Metadata in YAML
name: Name
creation: 2021-09-26 09:00:00+00:00
modification: 2021-09-26 09:00:00+00:00
targets:
  image: "./assets/image.png"
tags:
- tag1
- tag2
extra:
  key1: "value1"
  key2: "value2"
---

Description in Markdown.

Notes

<material>/notes/<note>.md contains the metadata (the structure is as same as material's description) and the content for the note for the material.

Assets

<material>/assets/ contains all additional files for the material, this will be directly served as static files, and all .md files for the material can access these files by using ./assets/... or ../assets/... (just relative path).

Development

# Run backend

cd src/main
python -m paperead -D "path/to/dataDir" serve
# endpoint: http://localhost:3649/api

# Run frontend
cd src/web
npm run dev
# endpoint: http://localhost:3000

Project details


Download files

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

Source Distribution

paperead-0.0.2.tar.gz (216.0 kB view hashes)

Uploaded Source

Built Distribution

paperead-0.0.2-py3-none-any.whl (220.4 kB view hashes)

Uploaded Python 3

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