Skip to content

Commit 35c985d

Browse files
Docs theme updates (#3751)
* update docs configs to use hugo theme from github * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * corrects the environment referenced in the docs/Makefile --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
1 parent 082a7c0 commit 35c985d

File tree

283 files changed

+44
-150748
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

283 files changed

+44
-150748
lines changed

docs/Makefile

Lines changed: 34 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,49 @@
1-
LOCAL_ROOT = $(git rev-parse --show-toplevel)
2-
SHELL = /bin/bash
3-
THEME_MODULE = gitlab.com/f5/nginx/controller/poc/f5-hugo
4-
# export THEME_PATH="</local/path/to/theme>"
5-
THEME_PATH = $(LOCAL_THEME_PATH)
6-
THEME_BRANCH = development
1+
THEME_MODULE = github.com/nginxinc/nginx-hugo-theme
2+
## Pulls the current theme version from the Netlify settings
3+
THEME_VERSION = $(NGINX_THEME_VERSION)
74

8-
.PHONY: all all-local clean hugo-mod build-production build-staging hugo-server-drafts hugo-server
5+
.PHONY: all clean hugo-mod build-production build-staging hugo-server-drafts hugo-server netlify
96

107
all: hugo-mod build-production
118

12-
all-local: clean hugo-mod build-production
9+
all-staging: hugo-mod build-staging
1310

11+
all-dev: hugo-mod build-dev
12+
13+
# Removes the public directory generated by the `hugo` command
1414
clean:
15-
rm -rf ${LOCAL_ROOT}/public
15+
if [[ -d ${PWD}/public ]] ; then rm -rf ${PWD}/public && echo "Removed public directory" ; else echo "Did not find a public directory to remove" ; fi
1616

1717
hugo-mod:
18-
hugo mod clean
19-
rm -rf _vendor
20-
hugo mod get
21-
hugo mod vendor
18+
hugo mod get $(THEME_MODULE)@v$(THEME_VERSION)
2219

20+
# Builds using the Hugo "production" environment
21+
# For deploys to docs.nginx.com only
2322
build-production:
2423
hugo --gc -e production
2524

25+
# Builds using the Hugo "staging" environment
26+
# For deploys to docs-staging.nginx.com only
2627
build-staging:
2728
hugo --gc -e staging
2829

29-
hugo-server-drafts:
30-
hugo server -e production -b 127.0.0.1/nginx-ingress-controller/ -D --disableFastRender
31-
32-
hugo-server:
33-
hugo server -e production -b 127.0.0.1/nginx-ingress-controller/ --disableFastRender
34-
35-
netlify:
36-
netlify build --context=branch-deploy
37-
netlify deploy -d public
38-
39-
replace-theme:
40-
go mod edit -replace "$(THEME_MODULE)"="$(THEME_PATH)"
30+
# Builds using the Hugo "development" environment
31+
# For deploys to docs-dev.nginx.com only
32+
build-dev:
33+
hugo --gc -e development
34+
35+
# Runs the Hugo server with content marked as draft
36+
# Serves docs at localhost:1313
37+
docs-drafts:
38+
hugo server -D --disableFastRender
39+
40+
# Runs the Hugo server
41+
# Serves docs at localhost:1313
42+
docs:
43+
hugo server --disableFastRender
44+
45+
# Can be used to deploy to netlify from your local
46+
# development environment.
47+
# Requires a netlify login.
48+
netlify: clean
49+
netlify deploy --build -d public --alias $(shell git branch --show-current)-branch

docs/_vendor/gitlab.com/f5/nginx/controller/poc/f5-hugo/archetypes/api.md

Lines changed: 0 additions & 17 deletions
This file was deleted.

docs/_vendor/gitlab.com/f5/nginx/controller/poc/f5-hugo/archetypes/blog.md

Lines changed: 0 additions & 7 deletions
This file was deleted.

docs/_vendor/gitlab.com/f5/nginx/controller/poc/f5-hugo/archetypes/concept.md

Lines changed: 0 additions & 44 deletions
This file was deleted.

docs/_vendor/gitlab.com/f5/nginx/controller/poc/f5-hugo/archetypes/default.md

Lines changed: 0 additions & 79 deletions
This file was deleted.

docs/_vendor/gitlab.com/f5/nginx/controller/poc/f5-hugo/archetypes/openapi.md

Lines changed: 0 additions & 30 deletions
This file was deleted.

0 commit comments

Comments
 (0)