# ensure consistent local version of node and npm are used:
nvm use
# install npm packages:
npm install
# use node to execute locally-installed http-server package:
npx http-server -p 8080
# use node to execute locally-installed linkinator package against local site:
npx linkinator http://127.0.0.1:8080 --recurse --verbosity error
# use node to execute locally-installed linkinator package against remote site:
npx linkinator https://cornermotorsales.com --recurse --verbosity error --format json &> linkinator-results.json
# open a pre-configured URL in a browser:
xdg-open https://validator.w3.org/checklink?uri=https%3A%2F%2Fcornermotorsales.com%2F&summary=on&hide_type=all&recursive=on&depth=2&check=Check
medium-speed, errors-only, complete details, structured results (csv or json)
see documentation: https://wummel.github.io/linkchecker/man1/linkchecker.1.html
# ensure pip is installed:
sudo apt update
sudo apt install python3-pip
# use pip to install LinkChecker:
sudo pip install LinkChecker
# use LinkChecker to check remote site:
linkchecker https://cornermotorsales.com --file-output=csv --check-extern
alternatively, using Docker:
sudo docker run --rm -it -u $(id -u):$(id -g) --log-driver=none -a stdout -a stderr linkchecker/linkchecker https://cornermotorsales.com --check-extern --no-status &> results.txt