Save SQL queries in Datasette
Install this plugin in the same environment as Datasette.
datasette install datasette-queries
Users with the datasette-queries
permission will see a new UI element on the results of a SQL query inviting them to save that query.
Saved queries (treated as canned queries) are then shown as a list on the database page.
To set up this plugin locally, first checkout the code. Then create a new virtual environment:
cd datasette-queries
python -m venv venv
source venv/bin/activate
Now install the dependencies and test dependencies:
pip install -e '.[test]'
To run the tests:
python -m pytest