https://github.com/john0isaac/markdown-checker
Markdown Links Validation Reporting Tool
https://github.com/john0isaac/markdown-checker
cli markdown pypi python tool
Last synced: 12 months ago
JSON representation
Markdown Links Validation Reporting Tool
- Host: GitHub
- URL: https://github.com/john0isaac/markdown-checker
- Owner: john0isaac
- License: mit
- Created: 2023-11-21T07:24:13.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2025-05-05T16:49:07.000Z (about 1 year ago)
- Last Synced: 2025-06-22T23:31:09.141Z (about 1 year ago)
- Topics: cli, markdown, pypi, python, tool
- Language: Python
- Homepage: https://pypi.org/project/markdown-checker
- Size: 135 KB
- Stars: 2
- Watchers: 2
- Forks: 2
- Open Issues: 9
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Contributing: CONTRIBUTING.md
- Funding: .github/FUNDING.yml
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
- Codeowners: .github/CODEOWNERS
Awesome Lists containing this project
README
[](https://pypi.org/project/markdown-checker/)
[](https://markdown-checker.readthedocs.io/en/latest/?badge=latest)
[](https://pypi.org/project/markdown-checker/)
[](https://github.com/john0isaac/markdown-checker/issues)
[](https://github.com/john0isaac/markdown-checker/pulls)
markdown-checker is a markdown link validation reporting tool. It provides a couple of functions to validate relative paths and web URLs.
## Installation
Install the package:
```bash
pip install markdown-checker
```
### Documentation
- [Full documentation](https://markdown-checker.readthedocs.io/en/latest/).
## 1, 2, 3 - How To
1. Run `pip install markdown-checker`.
2. Run `markdown-checker -d {src} -f {func} -gu {url}`. Replace `{src}` with the directory you want to analyze, `{func}` with the available functions like `check_broken_paths`, `{gu}` with your contribution guidance full URL.
3. The output will be displayed in the terminal and in a `comment.md` file.
For more customizations read the docs.
## Using `markdown-checker` in GitHub Actions
You can run this tool within a GitHub workflow using the [action-check-markdown](https://github.com/marketplace/actions/check-markdown) GitHub action.
The action will automatically post the output of the tool to your GitHub pull request as a comment.
# Usage
The library provides the following functions:
- [Usage](#usage)
- [`check_broken_paths`](#check_broken_paths)
- [`check_broken_urls`](#check_broken_urls)
- [`check_urls_locale`](#check_urls_locale)
- [`check_paths_tracking`](#check_paths_tracking)
- [`check_urls_tracking`](#check_urls_tracking)
## `check_broken_paths`
This function ensures that any relative path in your files are working.
Example:
```bash
markdown-checker -d . -f check_broken_paths -gu https://github.com/john0isaac/markdown-checker/blob/main/CONTRIBUTING.md
```
## `check_broken_urls`
This function ensures that any web URL in your files is working and returning 200 status code.
Example:
```bash
markdown-checker -d . -f check_broken_urls -gu https://github.com/john0isaac/markdown-checker/blob/main/CONTRIBUTING.md
```
## `check_urls_locale`
This function checks if country specific locale is present in URLs.
Example:
```bash
markdown-checker -d . -f check_urls_locale -gu https://github.com/john0isaac/markdown-checker/blob/main/CONTRIBUTING.md
```
## `check_paths_tracking`
This function ensures that any relative path has tracking in it.
Example:
```bash
markdown-checker -d . -f check_paths_tracking -gu https://github.com/john0isaac/markdown-checker/blob/main/CONTRIBUTING.md
```
## `check_urls_tracking`
This function ensures that any URL has tracking in it.
Example:
```bash
markdown-checker -d . -f check_urls_tracking -gu https://github.com/john0isaac/markdown-checker/blob/main/CONTRIBUTING.md
```