Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yasoob/logit-bin
A simple pastebin in Flask. Implements basic Authentication and uses WTForms and Flask-Sqlalchemy.
https://github.com/yasoob/logit-bin
Last synced: 4 days ago
JSON representation
A simple pastebin in Flask. Implements basic Authentication and uses WTForms and Flask-Sqlalchemy.
- Host: GitHub
- URL: https://github.com/yasoob/logit-bin
- Owner: yasoob
- Created: 2014-01-08T17:48:25.000Z (almost 11 years ago)
- Default Branch: master
- Last Pushed: 2014-06-14T23:53:47.000Z (over 10 years ago)
- Last Synced: 2024-10-31T21:35:46.486Z (13 days ago)
- Language: Python
- Homepage: http://logit-bin.herokuapp.com
- Size: 419 KB
- Stars: 13
- Watchers: 3
- Forks: 3
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Logit-bin
This repository contains code which I used to deploy a simple pastebin to Heroku. It utilizes WTForms and Flask-Sqlalchemy and uses basic Authentication using flask sessions. Just clone this repository and start using it. The website is also up on http://logit-bin.herokuapp.com
## Usage
### Initial
```bash
$ git clone [email protected]:yasoob/logit-bin.git
$ cd logit-bin
$ pip install -r requirements.txt
$ # you also need to make a sqlite database with the name `pastes.db`
$ foreman start
$ # in order to deploy it to heroku
$ # I am not including the steps to
$ # initialize a heroku app
$ git push heroku master
```### Database
```bash
$ heroku addons:add heroku-postgresql:dev
-----> Adding heroku-postgresql:dev to some-app-name... done, v196 (free)
Attached as HEROKU_POSTGRESQL_COLOR
Database has been created and is available
$ heroku pg:promote HEROKU_POSTGRESQL_COLOR
$ heroku run python
```and in the Python REPL:
```python
>>> from app import db
>>> db.create_all()
```##TODO:
- add tests
- ✓ use uuid_id field in url to display pastes in order to avoide paste enumeration
- add syntax highlighting using pygments
- allow line highlighting using target identifier like gist
- add facebook and twitter sharing
- introduce more features