-
Notifications
You must be signed in to change notification settings - Fork 76
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This commit updates the documentation Makefile and README, reflecting changes to it across NGINX's open source repositories for consistency. It removes unnecessary targets: Netlify is no longer used, nor was the Makefile used for Netlify for quite some time. The guidance for Makefile targets in the README is updated accordingly, as well formatting instructions for how we use Hugo contemporaneously.
- Loading branch information
1 parent
86b1fba
commit 4af5409
Showing
4 changed files
with
133 additions
and
156 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
HUGO?=hugo | ||
HUGO_IMG?=hugomods/hugo:0.115.3 | ||
|
||
THEME_MODULE = github.com/nginxinc/nginx-hugo-theme | ||
THEME_VERSION = 0.41.14 | ||
|
||
ifeq (, $(shell ${HUGO} version 2> /dev/null)) | ||
ifeq (, $(shell docker version 2> /dev/null)) | ||
$(error Docker and Hugo are not installed. Hugo (<0.91) or Docker are required to build the local preview.) | ||
else | ||
HUGO=docker run --rm -it -v ${CURDIR}:/src -p 1313:1313 ${HUGO_IMG} hugo --bind 0.0.0.0 -p 1313 | ||
endif | ||
endif | ||
|
||
MARKDOWNLINT?=markdownlint | ||
MARKDOWNLINT_IMG?=ghcr.io/igorshubovych/markdownlint-cli:latest | ||
|
||
ifeq (, $(shell ${MARKDOWNLINT} version 2> /dev/null)) | ||
ifeq (, $(shell docker version 2> /dev/null)) | ||
ifneq (, $(shell $(NETLIFY) "true")) | ||
$(error Docker and markdownlint are not installed. markdownlint or Docker are required to lint.) | ||
endif | ||
else | ||
MARKDOWNLINT=docker run --rm -i -v ${CURDIR}:/src --workdir /src ${MARKDOWNLINT_IMG} | ||
endif | ||
endif | ||
|
||
MARKDOWNLINKCHECK?=markdown-link-check | ||
MARKDOWNLINKCHECK_IMG?=ghcr.io/tcort/markdown-link-check:stable | ||
|
||
ifeq (, $(shell ${MARKDOWNLINKCHECK} --version 2> /dev/null)) | ||
ifeq (, $(shell docker version 2> /dev/null)) | ||
ifneq (, $(shell $(NETLIFY) "true")) | ||
$(error Docker and markdown-link-check are not installed. markdown-link-check or Docker are required to check links.) | ||
endif | ||
else | ||
MARKDOWNLINKCHECK=docker run --rm -it -v ${CURDIR}:/docs --workdir /docs ${MARKDOWNLINKCHECK_IMG} | ||
endif | ||
endif | ||
|
||
.PHONY: docs docs-draft docs-local clean hugo-get hugo-tidy lint-markdown link-check | ||
|
||
docs: | ||
${HUGO} | ||
|
||
watch: | ||
${HUGO} --bind 0.0.0.0 -p 1313 server --disableFastRender | ||
|
||
drafts: | ||
${HUGO} --bind 0.0.0.0 -p 1313 server -D --disableFastRender | ||
|
||
clean: | ||
[ -d "public" ] && rm -rf "public" | ||
|
||
hugo-get: | ||
hugo mod get $(THEME_MODULE)@v$(THEME_VERSION) | ||
|
||
hugo-tidy: | ||
hugo mod tidy | ||
|
||
hugo-update: hugo-get hugo-tidy | ||
|
||
lint-markdown: | ||
${MARKDOWNLINT} -c .markdownlint.yaml -- content | ||
|
||
link-check: | ||
${MARKDOWNLINKCHECK} $(shell find content -name '*.md') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,2 @@ | ||
github.com/nginxinc/nginx-hugo-theme v0.28.0 h1:RHHvBmFk2Uptk+efLPSIuBd2elc3IOZPElkJbkkpAHo= | ||
github.com/nginxinc/nginx-hugo-theme v0.28.0/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.33.0 h1:6mZdgxf5kNhInsrAXXiSlWXRy3fsP51lWKOdrvmkR6U= | ||
github.com/nginxinc/nginx-hugo-theme v0.33.0/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.34.0-alpha h1:8tKWnkhxP5Nk0V64v8rE9T3crusycohXl3wmOWc4uFk= | ||
github.com/nginxinc/nginx-hugo-theme v0.34.0-alpha/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.34.0 h1:G7LPVq7w1ls6IS4+OkTwjhFb67rLCzPdfZvW1/sn2Cw= | ||
github.com/nginxinc/nginx-hugo-theme v0.34.0/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.35.0 h1:7XB2GMy6qeJgKEJy9wOS3SYKYpfvLW3/H+UHRPLM4FU= | ||
github.com/nginxinc/nginx-hugo-theme v0.35.0/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.40.8 h1:VtoSAtf9k67tI2jzbLRo0oFBAMHZBUPRh/xV4MYullI= | ||
github.com/nginxinc/nginx-hugo-theme v0.40.8/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.41.9 h1:8TKgjocF95ZSRP0PHkyvk9TyJvwPrdz1k0FB5RfKT3I= | ||
github.com/nginxinc/nginx-hugo-theme v0.41.9/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= | ||
github.com/nginxinc/nginx-hugo-theme v0.41.14 h1:OraNB01CdMJXufPddvIVt6qn6Mj38Z/XCVIWBgVtuY0= | ||
github.com/nginxinc/nginx-hugo-theme v0.41.14/go.mod h1:DPNgSS5QYxkjH/BfH4uPDiTfODqWJ50NKZdorguom8M= |
This file was deleted.
Oops, something went wrong.