Skip to content
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

Fix error messages when running example site with hugo 0.138 #194

Open
wants to merge 1 commit into
base: release
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Check out the demo site [https://lotusdocs.dev/docs/](https://lotusdocs.dev/docs

### Requirements

- Hugo **Extended** (minimum version: 0.120.0)
- Hugo **Extended** (minimum version: 0.124.0)
- git
- Go (minimum version v1.20)

Expand Down
2 changes: 1 addition & 1 deletion config.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[module]
[module.hugoVersion]
extended = true
min = "0.120.0"
min = "0.124.0"
[[module.imports]]
path = "github.com/gohugoio/hugo-mod-bootstrap-scss/v5"
disable = false
2 changes: 1 addition & 1 deletion exampleSite/content/docs/example-content/mermaid.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ John->>Bob: How about you?
Bob-->>John: Jolly good!
```

## Gnatt Chart
## Gantt Chart

```mermaid
gantt
Expand Down
2 changes: 1 addition & 1 deletion layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@

<!-- Lotus Docs JS -->
{{ $app := resources.Get "/js/app.js" }}
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{- $js := (slice $app) | resources.Concat "/js/bundle.js" | minify | fingerprint "sha384" }}
<script type="text/javascript" src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}"></script>
{{- else }}
Expand Down
2 changes: 1 addition & 1 deletion layouts/docs/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
{{- partial (printf "%s/%s" ($.Scratch.Get "pathName") "sidebar.html") . -}}
<!-- Start Page Content -->
<main class="page-content bg-transparent">
{{ if .Site.IsMultiLingual }}
{{ if hugo.IsMultilingual }}
{{- partial (printf "%s/%s" ($.Scratch.Get "pathName") "top-header.html") . -}}
{{ else }}
{{- partialCached (printf "%s/%s" ($.Scratch.Get "pathName") "top-header.html") . -}}
Expand Down
2 changes: 1 addition & 1 deletion layouts/partials/docs/footer/footer-scripts.html
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@

{{ $js := $slice | resources.Concat (printf "/%s/%s" ($.Scratch.Get "pathName") "js/bundle.js") -}}

{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{- $js := $js | minify | fingerprint "sha384" }}
<script type="text/javascript" src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}" crossorigin="anonymous" defer></script>
{{- else }}
Expand Down
10 changes: 5 additions & 5 deletions layouts/partials/docs/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
{{ if and (.Site.Params.docsearch.appID) (.Site.Params.docsearch.apiKey) -}}
{{ else }}
{{ $flexSearch := resources.Get (printf "/%s/%s" ($.Scratch.Get "pathName") "js/flexsearch.bundle.js") }}
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{ $flexSearch := $flexSearch | minify | fingerprint "sha384" }}
<script type="text/javascript" src="{{ $flexSearch.Permalink }}" integrity="{{ $flexSearch.Data.Integrity }}" crossorigin="anonymous"></script>
{{ else }}
Expand All @@ -58,7 +58,7 @@
{{- $options := dict "enableSourceMap" false "outputStyle" "compressed" }}
{{- end }}
{{- $style := resources.Get (printf "/%s/%s" ($.Scratch.Get "pathName") "scss/style.scss") }}
{{- $style = $style | resources.ExecuteAsTemplate (printf "/%s/%s" ($.Scratch.Get "pathName") "scss/style.scss") . | resources.ToCSS $options }}
{{- $style = $style | resources.ExecuteAsTemplate (printf "/%s/%s" ($.Scratch.Get "pathName") "scss/style.scss") . | css.Sass $options }}
{{- if hugo.IsProduction }}
{{- $style = $style | minify | fingerprint "sha384" }}
{{- end -}}
Expand All @@ -70,7 +70,7 @@
{{- $options := dict "enableSourceMap" false "outputStyle" "compressed" }}
{{- end -}}
{{- $katexCSS := resources.Get (printf "/%s/%s" ($.Scratch.Get "pathName") "scss/katex.scss") }}
{{- $katexCSS = $katexCSS | resources.ExecuteAsTemplate (printf "/%s/%s" ($.Scratch.Get "pathName") "scss/katex.scss") . | resources.ToCSS $options }}
{{- $katexCSS = $katexCSS | resources.ExecuteAsTemplate (printf "/%s/%s" ($.Scratch.Get "pathName") "scss/katex.scss") . | css.Sass $options }}
{{- if hugo.IsProduction }}
{{- $katexCSS = $katexCSS | minify | fingerprint "sha384" }}
{{- end -}}
Expand All @@ -93,13 +93,13 @@
{{- partialCached (printf "%s/%s" ($.Scratch.Get "pathName") "footer/katex.html") . -}}
{{ end }}
<!-- Plausible Analytics Config -->
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{ if and (.Site.Params.plausible.scriptURL | default "https://plausible.io") (.Site.Params.plausible.dataDomain) -}}
{{- partialCached (printf "%s/%s" ($.Scratch.Get "pathName") "head/plausible") . }}
{{- end -}}
{{- end -}}
<!-- Google Analytics v4 Config -->
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{- if .Site.GoogleAnalytics }}
{{- template "_internal/google_analytics.html" . -}}
{{- end -}}
Expand Down
2 changes: 1 addition & 1 deletion layouts/partials/docs/head/opengraph.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
{{- end }}

{{- /* Facebook Page Admin ID for Domain Insights */}}
{{- with .Site.Social.facebook_admin }}<meta property="fb:admins" content="{{ . }}" />{{ end }}
{{- with .Site.Params.Social.facebook_admin }}<meta property="fb:admins" content="{{ . }}" />{{ end }}
2 changes: 1 addition & 1 deletion layouts/partials/docs/head/twitter_cards.html
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,6 @@
{{- end }}
<meta name="twitter:title" content="{{ .Title }}"/>
<meta name="twitter:description" content="{{ with .Description }}{{ . }}{{ else }}{{if .IsPage}}{{ .Summary }}{{ else }}{{ with .Site.Params.description }}{{ . }}{{ end }}{{ end }}{{ end -}}"/>
{{ with .Site.Social.twitter -}}
{{ with .Site.Params.Social.twitter -}}
<meta name="twitter:site" content="@{{ . }}"/>
{{ end -}}
2 changes: 1 addition & 1 deletion layouts/partials/docs/top-header.html
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@
</span>
</button>
{{ end -}}
{{ if .Site.IsMultiLingual }}
{{ if hugo.IsMultilingual }}
<div class="dropdown">
<button class="btn btn-link btn-default dropdown-toggle ps-2" type="button" data-bs-toggle="dropdown" aria-expanded="false">
{{ site.Language.Lang | upper }}
Expand Down
8 changes: 4 additions & 4 deletions layouts/partials/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
{{- $options := dict "enableSourceMap" false "outputStyle" "compressed" }}
{{- end }}
{{- $style := resources.Get "/scss/style.scss" }}
{{- $style = $style | resources.ExecuteAsTemplate "/scss/style.scss" . | resources.ToCSS $options }}
{{- $style = $style | resources.ExecuteAsTemplate "/scss/style.scss" . | css.Sass $options }}
{{- if hugo.IsProduction }}
{{- $style = $style | minify | fingerprint "sha384" }}
{{- end -}}
Expand All @@ -39,7 +39,7 @@
<!-- Image Compare Viewer -->
{{ if ($.Scratch.Get "image_compare_enabled") }}
{{ $imagecompare := resources.Get "js/image-compare-viewer.min.js" }}
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{- $js := (slice $imagecompare) | resources.Concat "/js/image-compare.js" | minify | fingerprint "sha384" }}
<script type="text/javascript" src="{{ $js.Permalink }}" integrity="{{ $js.Data.Integrity }}"></script>
{{- else }}
Expand All @@ -48,13 +48,13 @@
{{- end }}
{{- end }}
<!-- Plausible Analytics Config -->
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{ if and (.Site.Params.plausible.scriptURL) (.Site.Params.plausible.dataDomain) -}}
{{- partialCached "head/plausible" . }}
{{- end -}}
{{- end -}}
<!-- Google Analytics v4 Config -->
{{- if not .Site.IsServer }}
{{- if not hugo.IsServer }}
{{- if .Site.GoogleAnalytics }}
{{- template "_internal/google_analytics.html" . -}}
{{- end -}}
Expand Down
2 changes: 1 addition & 1 deletion netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@ command = "cd exampleSite && hugo --gc --minify --themesDir ../.. -b ${DEPLOY_PR
ignore = "false"

[build.environment]
HUGO_VERSION = "0.120.4"
HUGO_VERSION = "0.124.1"
2 changes: 1 addition & 1 deletion theme.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ homepage = "https://github.com/colinwilson/lotusdocs"
demosite = "https://lotusdocs.dev/docs/"
tags = ["documentation", "responsive", "bootstrap", "minimal", "secure", "search", "customizable", "modern","dark", "dark mode", "landing page"]
features = ["security aware", "fast by default", "seo-ready","custom shortcodes", "prismjs syntax highlighting", "deploy to vercel", "flexsearch static search", "docsearch", "landing page layouts", "dark mode"]
min_version = "0.120.0"
min_version = "0.124.0"

[author]
name = "Colin Wilson"
Expand Down