# mdformat-tables
[![Build Status][ci-badge]][ci-link]
[![codecov.io][cov-badge]][cov-link]
[![PyPI version][pypi-badge]][pypi-link]
An [mdformat](https://github.com/executablebooks/mdformat) plugin for rendering tables.
For example, converting:
```markdown
a | b | c
:- | -: | :-:
1 | 2 | 3
xxxxxx | yyyyyy | zzzzzz
```
to:
```markdown
| a | b | c |
| :----- | -----: | :----: |
| 1 | 2 | 3 |
| xxxxxx | yyyyyy | zzzzzz |
```
For further examples, see tests/fixtures.md in the repository.
## Development
This package utilises [flit](https://flit.readthedocs.io) as the build engine, and [tox](https://tox.readthedocs.io) for test automation.
To install these development dependencies:
```bash
pip install flit tox
```
To run the tests:
```bash
tox
```
To run the code formatting and style checks:
```bash
tox -e py37-pre-commit
```
or directly
```bash
pip install pre-commit
pre-commit run --all
```
To run the pre-commit hook test:
```bash
tox -e py37-hook
```
## Publish to PyPi
Either use flit directly:
```bash
flit publish
```
or trigger the GitHub Action job, by creating a release with a tag equal to the version, e.g. `v0.0.1`.
Note, this requires generating an API key on PyPi and adding it to the repository `Settings/Secrets`, under the name `PYPI_KEY`.
[ci-badge]: https://github.com/executablebooks/mdformat-tables/workflows/CI/badge.svg?branch=master
[ci-link]: https://github.com/executablebooks/mdformat/actions?query=workflow%3ACI+branch%3Amaster+event%3Apush
[cov-badge]: https://codecov.io/gh/executablebooks/mdformat-tables/branch/master/graph/badge.svg
[cov-link]: https://codecov.io/gh/executablebooks/mdformat-tables
[pypi-badge]: https://img.shields.io/pypi/v/mdformat-tables.svg
[pypi-link]: https://pypi.org/project/mdformat-tables
Raw data
{
"_id": null,
"home_page": "https://github.com/executablebooks/mdformat-tables",
"name": "mdformat_tables",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.7.0",
"maintainer_email": null,
"keywords": "mdformat, markdown, markdown-it",
"author": "Chris Sewell",
"author_email": "executablebooks@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/64/fc/995ba209096bdebdeb8893d507c7b32b7e07d9a9f2cdc2ec07529947794b/mdformat_tables-1.0.0.tar.gz",
"platform": null,
"description": "# mdformat-tables\n\n[![Build Status][ci-badge]][ci-link]\n[![codecov.io][cov-badge]][cov-link]\n[![PyPI version][pypi-badge]][pypi-link]\n\nAn [mdformat](https://github.com/executablebooks/mdformat) plugin for rendering tables.\n\nFor example, converting:\n\n```markdown\na | b | c\n:- | -: | :-:\n1 | 2 | 3\nxxxxxx | yyyyyy | zzzzzz\n```\n\nto:\n\n```markdown\n| a | b | c |\n| :----- | -----: | :----: |\n| 1 | 2 | 3 |\n| xxxxxx | yyyyyy | zzzzzz |\n```\n\nFor further examples, see tests/fixtures.md in the repository.\n\n## Development\n\nThis package utilises [flit](https://flit.readthedocs.io) as the build engine, and [tox](https://tox.readthedocs.io) for test automation.\n\nTo install these development dependencies:\n\n```bash\npip install flit tox\n```\n\nTo run the tests:\n\n```bash\ntox\n```\n\nTo run the code formatting and style checks:\n\n```bash\ntox -e py37-pre-commit\n```\n\nor directly\n\n```bash\npip install pre-commit\npre-commit run --all\n```\n\nTo run the pre-commit hook test:\n\n```bash\ntox -e py37-hook\n```\n\n## Publish to PyPi\n\nEither use flit directly:\n\n```bash\nflit publish\n```\n\nor trigger the GitHub Action job, by creating a release with a tag equal to the version, e.g. `v0.0.1`.\n\nNote, this requires generating an API key on PyPi and adding it to the repository `Settings/Secrets`, under the name `PYPI_KEY`.\n\n[ci-badge]: https://github.com/executablebooks/mdformat-tables/workflows/CI/badge.svg?branch=master\n[ci-link]: https://github.com/executablebooks/mdformat/actions?query=workflow%3ACI+branch%3Amaster+event%3Apush\n[cov-badge]: https://codecov.io/gh/executablebooks/mdformat-tables/branch/master/graph/badge.svg\n[cov-link]: https://codecov.io/gh/executablebooks/mdformat-tables\n[pypi-badge]: https://img.shields.io/pypi/v/mdformat-tables.svg\n[pypi-link]: https://pypi.org/project/mdformat-tables\n",
"bugtrack_url": null,
"license": null,
"summary": "An mdformat plugin for rendering tables.",
"version": "1.0.0",
"project_urls": {
"Homepage": "https://github.com/executablebooks/mdformat-tables"
},
"split_keywords": [
"mdformat",
" markdown",
" markdown-it"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "2a37d78e37d14323da3f607cd1af7daf262cb87fe614a245c15ad03bb03a2706",
"md5": "6a6813d7eb2e02c89f1e981b7a244c1a",
"sha256": "94cd86126141b2adc3b04c08d1441eb1272b36c39146bab078249a41c7240a9a"
},
"downloads": -1,
"filename": "mdformat_tables-1.0.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "6a6813d7eb2e02c89f1e981b7a244c1a",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7.0",
"size": 5104,
"upload_time": "2024-08-23T23:41:31",
"upload_time_iso_8601": "2024-08-23T23:41:31.863073Z",
"url": "https://files.pythonhosted.org/packages/2a/37/d78e37d14323da3f607cd1af7daf262cb87fe614a245c15ad03bb03a2706/mdformat_tables-1.0.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "64fc995ba209096bdebdeb8893d507c7b32b7e07d9a9f2cdc2ec07529947794b",
"md5": "b87a9f9405d7be94e96992bd8bf93ad7",
"sha256": "a57db1ac17c4a125da794ef45539904bb8a9592e80557d525e1f169c96daa2c8"
},
"downloads": -1,
"filename": "mdformat_tables-1.0.0.tar.gz",
"has_sig": false,
"md5_digest": "b87a9f9405d7be94e96992bd8bf93ad7",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7.0",
"size": 6106,
"upload_time": "2024-08-23T23:41:33",
"upload_time_iso_8601": "2024-08-23T23:41:33.413872Z",
"url": "https://files.pythonhosted.org/packages/64/fc/995ba209096bdebdeb8893d507c7b32b7e07d9a9f2cdc2ec07529947794b/mdformat_tables-1.0.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-08-23 23:41:33",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "executablebooks",
"github_project": "mdformat-tables",
"travis_ci": false,
"coveralls": false,
"github_actions": true,
"tox": true,
"lcname": "mdformat_tables"
}