mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-07-23 09:24:31 +02:00
Use cog to maintain --fmt list, closes #373
This commit is contained in:
parent
e0c476bc38
commit
148e9c7aee
4 changed files with 43 additions and 2 deletions
3
.github/workflows/test.yml
vendored
3
.github/workflows/test.yml
vendored
|
|
@ -41,3 +41,6 @@ jobs:
|
|||
run: flake8
|
||||
- name: Check formatting
|
||||
run: black . --check
|
||||
- name: Check if cog needs to be run
|
||||
run: |
|
||||
cog --check README.md docs/*.rst
|
||||
|
|
|
|||
36
docs/cli.rst
36
docs/cli.rst
|
|
@ -176,7 +176,41 @@ You can use the ``--fmt`` option to specify different table formats, for example
|
|||
2 2 Pancakes
|
||||
==== ===== ========
|
||||
|
||||
For a full list of table format options, run ``sqlite-utils query --help``.
|
||||
Available ``--fmt`` options are:
|
||||
|
||||
.. [[[cog
|
||||
import tabulate
|
||||
cog.out("\n" + "\n".join('- ``{}``'.format(t) for t in tabulate.tabulate_formats) + "\n\n")
|
||||
.. ]]]
|
||||
|
||||
- ``fancy_grid``
|
||||
- ``fancy_outline``
|
||||
- ``github``
|
||||
- ``grid``
|
||||
- ``html``
|
||||
- ``jira``
|
||||
- ``latex``
|
||||
- ``latex_booktabs``
|
||||
- ``latex_longtable``
|
||||
- ``latex_raw``
|
||||
- ``mediawiki``
|
||||
- ``moinmoin``
|
||||
- ``orgtbl``
|
||||
- ``pipe``
|
||||
- ``plain``
|
||||
- ``presto``
|
||||
- ``pretty``
|
||||
- ``psql``
|
||||
- ``rst``
|
||||
- ``simple``
|
||||
- ``textile``
|
||||
- ``tsv``
|
||||
- ``unsafehtml``
|
||||
- ``youtrack``
|
||||
|
||||
.. [[[end]]]
|
||||
|
||||
This list can also be found by running ``sqlite-utils query --help``.
|
||||
|
||||
.. _cli_query_raw:
|
||||
|
||||
|
|
|
|||
|
|
@ -44,6 +44,10 @@ Then run ``make livehtml`` from the ``docs/`` directory to start a server on por
|
|||
cd docs
|
||||
make livehtml
|
||||
|
||||
The `cog <https://github.com/nedbat/cog>`__ tool is used to maintain portions of the documentation. You can run it like so::
|
||||
|
||||
cog -r docs/*.rst
|
||||
|
||||
.. _contributing_linting:
|
||||
|
||||
Linting and formatting
|
||||
|
|
|
|||
2
setup.py
2
setup.py
|
|
@ -31,7 +31,7 @@ setup(
|
|||
"python-dateutil",
|
||||
],
|
||||
extras_require={
|
||||
"test": ["pytest", "black", "hypothesis"],
|
||||
"test": ["pytest", "black", "hypothesis", "cogapp"],
|
||||
"docs": ["sphinx_rtd_theme", "sphinx-autobuild", "codespell"],
|
||||
"mypy": [
|
||||
"mypy",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue