Skip to main content

A Python wrapper around jackdewinter's PyMarkdown linter to suppress errors, caused by custom-formatted tables in Markdown files

This project has been archived.

The maintainers of this project have marked this project as archived. No new releases are expected.

Project description

CCFT-PyMarkdown

CCFT-PyMarkdown PyPI Version Python Version PyMarkdown Version Tests Status mypy Status pre-commit Status Ruff uv

A Python wrapper around jackdewinter's PyMarkdown linter to suppress errors, caused by custom-formatted tables in Markdown files

When running PyMarkdown it may incorrectly flag errors inside a table that has correct formatting. Using this wrapper, the errors will be suppressed by temporarily cleaning any custom-formatted tables.

Installation

Run as a uv tool (no installation necessary)

uvx -- ccft-pymarkdown --help

Install permenantly as a uv tool

uv tool install CCFT-PyMarkdown

Install using pip after creating a virtual environment

path/to/venv/python -m pip install CCFT-PyMarkdown

The +[git-python]+ https://packaging.python.org/specifications/dependency-specifiers#extras[Extra]

This package can also be installed with the [git-python] optional dependency. This will allow the identification of hidden/excluded files to make use of your project’s .gitignore file.

Run as a uv tool (no installation necessary)

uvx --from CCFT-PyMarkdown[git-python] -- ccft-pymarkdown --help

Install permenantly as a uv tool

uv tool install CCFT-PyMarkdown[git-python]

Install using pip after creating a virtual environment

path/to/venv/python -m pip install CCFT-PyMarkdown[git-python]

Usage

These commands will only work correctly either after installation as a permenant uv tool, or after activating a virtual environment with CCFT-PyMarkdown installed. Replace the command name ccft-pymarkdown with uvx -- ccft-pymarkdown, to run any of the following commands in an ephemeral envrionment.

💡 TIP
If you require sending additional arguments to the pymarkdown command you must manually clean any custom-formatted tables and then manually restore the MarkDown files.

Output the help message

ccft-pymarkdown --help

Run with increased verbosity

ccft-pymarkdown <command> -v

Run without any logging output (incompatible with the -v flag)

ccft-pymarkdown <command> -q

Output the current version number

ccft-pymarkdown --version

Scanning All Files After Cleaning Custom-Formatted Tables

To perform linting using PyMarkdown, after cleaning custom-formatted tables within any MarkDown files, use the scan-all action

ccft-pymarkdown scan-all

Scan files according to your .gitignore file (Only available when the [git-python] extra is installed)

ccft-pymarkdown scan-all --with-git

Scan files without ignoring any hidden/excluded files

ccft-pymarkdown scan-all --no-git

Manually Cleaning Custom-Formatted Tables

To manually clean custom-formatted-tables within any MarkDown files without running PyMarkdown, use the clean action

ccft-pymarkdown clean MyNotes.md MyReport.md

Clean a whole directory and additional files

ccft-pymarkdown clean my-notes/ MyReport.md

Clean a whole directory according to your .gitignore file (Only available when the [git-python] extra is installed)

ccft-pymarkdown clean --with-git my-notes/

Clean a whole directory without ignoring any hidden/excluded files

ccft-pymarkdown clean --no-git my-notes/

Clean files without making any changes, only report what would have been changed

ccft-pymarkdown clean --dry-run MyNotes.md MyReport.md

Manually Restoring https://wikipedia.org/wiki/Markdown[MarkDown] Files

To manually restore any cleaned MarkDown files, use the restore action

ccft-pymarkdown restore MyNotes.md MyReport.md

Restore a whole directory and additional files

ccft-pymarkdown restore my-notes/ MyReport.md

Restore files without making any changes, only report what would have been changed

ccft-pymarkdown restore --dry-run MyNotes.md MyReport.md

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ccft_pymarkdown-2.2.0.tar.gz (16.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ccft_pymarkdown-2.2.0-py3-none-any.whl (18.9 kB view details)

Uploaded Python 3

File details

Details for the file ccft_pymarkdown-2.2.0.tar.gz.

File metadata

  • Download URL: ccft_pymarkdown-2.2.0.tar.gz
  • Upload date:
  • Size: 16.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.8.22

File hashes

Hashes for ccft_pymarkdown-2.2.0.tar.gz
Algorithm Hash digest
SHA256 0adfb9d5abbdf5c9b1a1ed26fc24698323063d173ab2f48edb4705f937812e4f
MD5 7fc1486419f6b9931eb2d047c0a78655
BLAKE2b-256 64b225ed3df3d2ae1c2b6c1f76f74dd062fb6feabc42389f55110fe26e7cda38

See more details on using hashes here.

File details

Details for the file ccft_pymarkdown-2.2.0-py3-none-any.whl.

File metadata

File hashes

Hashes for ccft_pymarkdown-2.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 96f70d017df75f4728b21c5446ea87d4ef8b03dcab4973e4bad3d306c505063c
MD5 5058101d411b8f01759a1e899840d153
BLAKE2b-256 ecdf938778e495118f8ba29c8d48e3059771093a3828758429dcd159ee5c0527

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page