Simple CLI tool to check URL health in markdown files.
Project description
Markdown URL Checker
>> Simple CLI tool to check URL health in markdown files <<
This CLI tool traverses down a markdown file, extracts all the valid URLs, and checks whether they're accessible or not. In case it encounters a broken link, it raises an error. Internally, this is optimized for larger markdown files and tested for huge markdown files with thousands of links.
Installation
Install the CLI using pip:
pip install md-url-checker
Usage
-
To check the URLs in a single markdown file, run:
md-url-check -f file.md
-
To check the URLs in multiple markdown files, run:
echo 'file1.md file2.md' | xargs -n 1 md-url-check -f
-
To check the URLs in multiple files in a folder, run:
find . -name '*.md' | xargs -n 1 --no-run-if-empty md-url-check -f
-
Suppress intermediate output:
md-url-check -f file.md -s
-
Provide the number of threads to be used while making the requests:
md-url-check -f file.md -s -t 32
This uses 32 interleaving threads to make the requests concurrently. Default is 8.
Know Issues
Currently, the checker fails for urls with parenthesis in them, for example:
https://en.wikipedia.org/wiki/John_Gall_(author)
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
Built Distribution
Hashes for md_url_check-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 26a13df97b7f5cf0ee690f787f30efca34a19637e94b7173605a61961b91d374 |
|
MD5 | 3f7bf395e9dce82e3df7b37c3d59873c |
|
BLAKE2b-256 | eac46656d25229a3a222dec6aa9455decd2a0ace4d8180826d4ab5f7c44eb1e5 |