malte70 / flyingpaste

A simple Nopaste service

Home Page:https://nopaste.rt3x.de

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Flying Paste

What's this

Flying Paste is a Nopaste application based on Python featuring syntax highlighting and full database storage (no write access to any file required).

Requirements

  • Python 3
  • bottle
  • Pygments
  • Python-MySQL
  • a running MySQL server

Installation

  • Get the latest code from github with:
    git clone https://github.com/malte70/flyingpaste
  • Optional: create a special database user for the application
  • Create a table using the following SQL statement:
    CREATE TABLE pastes (
    	id VARCHAR(20) NOT NULL PRIMARY KEY,
    	title VARCHAR(200) DEFAULT "Untitled",
    	description TEXT DEFAULT NULL,
    	author_name VARCHAR(50) DEFAULT "Anonymous",
    	author_email VARCHAR(50) DEFAULT NULL,
    	code TEXT NOT NULL,
    	language VARCHAR(20) DEFAULT "text",
    	privacy VARCHAR(20) DEFAULT "public",
      date_added datetime NOT NULL DEFAULT current_timestamp()
    ) DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci;
  • Generate a configuration using the configure script:
    cd flyingpaste
    ./configure

Running

Run directly in testing mode

Simply execute flyingpaste.py from the command line:

cd /path/to/flyingpaste
python flyingpaste.py

Run using Apache's mod_wsgi

A sample configuration is included in the source as doc/apache-example.conf. Modify it for your needs, activate mod_wsgi and restart your Apache server. You're done!

Homepage and source code repository

Available on github: https://github.com/malte70/flyingpaste No website at the moment (there will be one later)

Licensing

Flying Paste is free/libre software released under the MIT license, which can be found in the file LICENSE.

Submitting bugs/feature requests

If you have found a bug or like to see a specific feature, open an issue on github (https://github.com/malte70/flyingpaste/issues/new) or leave me an EMail (see "Contacting the author").

About

A simple Nopaste service

https://nopaste.rt3x.de

License:MIT License


Languages

Language:Python 53.4%Language:Smarty 26.8%Language:CSS 15.2%Language:Shell 4.6%