Extracts links in markup files.
Currently html
and markdown
files are supported.
The main intended purpose of the Markup Link Extractor,
is to extract links fro ma set of files,
and then check them for validity using a separate tool,
e.g. the Markdown Link Checker.
Together, two such tools could be integrated in your CI pipeline
to warn about broken links in your markup docs.
- Find links in
markdown
andhtml
files - Support HTML links and plain URLs in
markdown
files - User friendly command line interface
- Easy CI pipeline integration
- Very fast execution using async
There are different ways to install and use mle.
Use rust's package manager cargo to install mle from crates.io:
cargo install mle
To download a compiled binary version of mle
go to github releases
and download the binaries compiled for x86_64-unknown-linux-gnu
or x86_64-apple-darwin
.
Use mle in GitHub using the GitHub-Action from the Marketplace.
- name: Markup Link Extractor (mle)
uses: hoijui/[email protected]
Use mle command line arguments using the with
argument:
- name: Markup Link Extractor (mle)
uses: hoijui/[email protected]
with:
args: ./README.md
To integrate mle in your CI pipeline running in a linux x86_64 environment, you can add the following commands to download the tool:
curl -L https://github.com/hoijui/mle/releases/download/v0.14.3/mle -o mle
chmod +x mle
For example take a look at the ntest repo which uses mle in the CI pipeline.
Use the mle docker image from the docker hub, which includes mle.
Once you have mle installed, it can be called from the command line. The following call will extract all links in markup files found in the current folder and all subdirectories:
mle
Another example is to call mle on a certain directory or file:
mle ./docs
Call mle with the --help
flag to display all available cli arguments:
mle -h
See the reference for all available command line arguments.
This project was funded by the European Regional Development Fund (ERDF)
in the context of the INTERFACER Project,
from July 2022 (fork from mlc
/project start)
until March 2023.