-
Notifications
You must be signed in to change notification settings - Fork 76
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update documentation Makefile and README #820
Closed
Closed
Changes from 2 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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,65 @@ | ||
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)) | ||
$(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)) | ||
$(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} | ||
ADubhlaoich marked this conversation as resolved.
Show resolved
Hide resolved
|
||
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.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this
endif
needed?