# Snape
Snape is a minimalism snippets manager written in Python. You may add/search a snippet, all data is saved into a local json file, you can modify the json file at will and put that file with other dot files under version control.
Of course the name comes from Harry Potter, as mentioned by Harry potter:
> He was probably the bravest man I ever knew.
I think we all need a little bravery from time to time.
# Installation and usage
The installation is plain and simple, just use pip to install it.
` pip install Snape `
To add a snippet, run Snape add [name of snippeet], for example:
` {~}Snape add python post json Enter/Paste your content. Ctrl-D to save it. import requests, json url = 'http://127.0.0.1:27182/api/account' headers = {'Content-type': 'application/json', 'Accept': 'text/plain'} data = {'name': 1, 'param': 2} response = requests.post(url, data=json.dumps(data), headers=headers} `
Please note that after you have added all the data there, you need to add an Enter and a Ctrl-D to send an EOL to mark the end of the stream.
After that, the snippet would be saved to ~/.snape.json.
You can list all the snippets by running Snape. You can also search the snippets with Snape search [query] to look for the snippet you need.
There’s no intention to add the ability to modify or remove a snippet, since you can easily do that with any editor you like.
Release files for Snape 1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| Snape-1.0.tar.gz | 3.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| Snape-1.0-py2-none-any.whl | Python 2 | none | any | Details |
Total release size: 6.7 kB
Release files / Snape-1.0.tar.gz
| Download URL | Snape-1.0.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9a9acc45f0cc670b6024bfb48a44c6feca46837b02c6297db97c30272f5c6cf0
|
|
BLAKE2b-256 checksum How to use checksums |
6b1dd5b58ee16cc0b1b016f5fe7ad498b8e1f2adcc115b709eeadc2b1fce8172
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / Snape-1.0-py2-none-any.whl
| Download URL | Snape-1.0-py2-none-any.whl |
|---|---|
| Size | 3.5 kB |
| Tags | Python 2 |
|
SHA-256 checksum How to use checksums |
76c24332c46e6b9a594e7887b8309b82577785614fc167edca80e3a16ce0dc6f
|
|
BLAKE2b-256 checksum How to use checksums |
51d436f1ee13a4f8b83d77b32a6ade239470592de3fd7ed887e57cb6ca53e5c2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |