diff options
author | Clément Bénier <clement.benier@iot.bzh> | 2019-03-29 16:43:47 +0100 |
---|---|---|
committer | Clément Bénier <clement.benier@iot.bzh> | 2019-03-29 16:43:47 +0100 |
commit | 657afcf4e2bb93255d722b8019a2a352ffc534d1 (patch) | |
tree | 22d11fda0923c434ceb494b2a46bc766e8541ed3 /Makefile | |
parent | 768b049078c083436dcb7eeebfd816c68f2aa5cf (diff) |
Makefile: add linkchecker rule to check links
Signed-off-by: Clément Bénier <clement.benier@iot.bzh>
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -15,6 +15,7 @@ help: @echo -e "- make build VERSIONS=[VERSION,...] SECTIONS=[SECTION,...]: build the site" @echo -e "- make push VERSIONS=[VERSION,...] SECTIONS=[SECTION,...]: push the built site" @echo -e "- make serve VERSIONS=[VERSION,...] SECTIONS=[SECTION,...]: serve the site" + @echo -e "- make linkchecker: check link in the local site, PORT=[default:4000]" @echo -e @echo -e "VERSIONS=" @echo -e "\t represents the desired versions, separated with ," @@ -56,3 +57,10 @@ push: $(FETCHTS) serve: $(FETCHTS) $(DOCBUILD) $(VERBOSE) --build --serve +.PHONY: linkchecker +linkchecker: $(FETCHS) + @which linkchecker &> /dev/null || { echo "No linkchecker found, please install linkchecker"; exit -1; } + @curl http://localhost:4000 &> /dev/null || { echo "No localhost:4000 found: Please run make serve before checking localsite"; exit -1; } + linkchecker http://localhost:4000 + + |