Shell helper utilities for python
Project description
gripe | |
Opinionated extensions for the `grip` utility. The grip utility provides rendering/serving local markdown files written in github-flavored markdown. Gripe extends it, allowing for serving more types of local files, as well as intelligent management for multiple `grip` daemons. |
Overview
The gripe
library provides extensions for grip.
The grip utility provides rendering/serving local markdown files written in github-flavored markdown.
Gripe extends it, allowing for serving more types of local files, as well as intelligent management for multiple grip
daemons.
Features
Support for Multiple Projects
Working with multiple projects simultaneously is supported. This works by managing multiple daemons with a per-project port. See CLI Usage for more information.
Installation
See pypi for available releases.
$ pip install gripe
Usage (CLI)
The gripe library publishes a small CLI tool.
Listing Servers
# or `gripe ls` or `python -mgripe ls`
$ gripe list
{"local": [], "foreign": []}
Starting and Stopping Servers
# or `python -mgripe start`
$ gripe start
INFO gripe Trying to serve files
DEBUG gripe Starting gripe for this project..
DEBUG gripe Used ports: []
INFO gripe starting server with command:
INFO gripe 'flask --app gripe:app run
--port 6149 >> .tmp.gripe.log 2>&1 &'
$ gripe start
INFO gripe Trying to serve files
INFO gripe 1 copies of gripe are already started
INFO gripe gripe @ pid `10059` is already serving this project
INFO gripe Skipping startup.
$ gripe stop
INFO gripe gripe @ {'pid': 10059, 'cwd':'...', 'port': 6149} started here
INFO gripe killing it..
Usage (API)
Listing Servers
>>> import gripe
>>> gripe.list()
{"local": [], "foreign": []}
Starting and Stopping Servers
>>> import gripe
>>> servers = gripe.start(); print(servers)
{ "local": [
{ "pid": 93867,
"cwd": "...",
"port": 6149 }
],
"foreign": []
}
>>> gripe.stop(grips=servers['local'])
{
"killed":
[ { "pid": 93867,
"cwd": "...",
"port": 6149 } ]
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
gripe-2024.2.17.20.32.tar.gz
(7.5 kB
view hashes)
Built Distribution
Close
Hashes for gripe-2024.2.17.20.32-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2fd2a4e58180fa3760c7737ba211c19361adaaebba2edd20eddd431fd9266993 |
|
MD5 | cf3f432a062730e3d2c429eae50e2c19 |
|
BLAKE2b-256 | 57abe1116b556708d8f212344b05c815f05336ad39ccec9b028583f856b1bf58 |