Skip to content

Commit

Permalink
address Hugo deprecations
Browse files Browse the repository at this point in the history
  • Loading branch information
jfredrickson committed Jul 5, 2024
1 parent f235b8f commit 6b1ebff
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 15 deletions.
15 changes: 8 additions & 7 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"description": "Hugo-based ejeff.org website",
"scripts": {
"start": "concurrently npm:serve:default npm:serve:retro",
"serve:default": "hugo server --buildDrafts --buildFuture --noHTTPCache --bind 0.0.0.0 --port 1313 --verbose --disableFastRender --ignoreCache --config config.yml,config.default.yml",
"serve:retro": "hugo server --buildDrafts --buildFuture --noHTTPCache --bind 0.0.0.0 --port 1314 --verbose --disableFastRender --ignoreCache --config config.yml,config.retro.yml",
"serve:default": "hugo server --buildDrafts --buildFuture --noHTTPCache --bind 0.0.0.0 --port 1313 --logLevel info --disableFastRender --ignoreCache --config config.yml,config.default.yml",
"serve:retro": "hugo server --buildDrafts --buildFuture --noHTTPCache --bind 0.0.0.0 --port 1314 --logLevel info --disableFastRender --ignoreCache --config config.yml,config.retro.yml",
"build": "npm run build:default && npm run build:retro",
"build:default": "hugo --config config.yml,config.default.yml",
"build:retro": "hugo --config config.yml,config.retro.yml"
Expand Down
6 changes: 3 additions & 3 deletions themes/default/layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,12 @@

<script defer data-domain="ejeff.org" src="https://plausible.tensouth.net/js/script.js"></script>

{{- if .Site.IsServer -}}
{{- if hugo.IsServer -}}
{{- $random := md5 now.Unix -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | resources.PostCSS | resources.ExecuteAsTemplate (printf "tailwind.dev.%s.css" $random) . -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | css.PostCSS | resources.ExecuteAsTemplate (printf "tailwind.dev.%s.css" $random) . -}}
<link rel="stylesheet" href="{{ $tailwind.RelPermalink }}">
{{- else -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | resources.PostCSS | resources.Fingerprint | resources.Minify -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | css.PostCSS | resources.Fingerprint | resources.Minify -}}
<link rel="stylesheet" href="{{ $tailwind.RelPermalink }}">
{{- end -}}

Expand Down
6 changes: 3 additions & 3 deletions themes/retro/layouts/_default/baseof.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@

<script defer data-domain="retro.ejeff.org" src="https://plausible.tensouth.net/js/script.js"></script>

{{- if .Site.IsServer -}}
{{- if hugo.IsServer -}}
{{- $random := md5 now.Unix -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | resources.PostCSS | resources.ExecuteAsTemplate (printf "tailwind.dev.%s.css" $random) . -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | css.PostCSS | resources.ExecuteAsTemplate (printf "tailwind.dev.%s.css" $random) . -}}
<link rel="stylesheet" href="{{ $tailwind.RelPermalink }}">
{{- else -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | resources.PostCSS | resources.Fingerprint | resources.Minify -}}
{{- $tailwind := resources.Get "/css/tailwind.css" | css.PostCSS | resources.Fingerprint | resources.Minify -}}
<link rel="stylesheet" href="{{ $tailwind.RelPermalink }}">
{{- end -}}

Expand Down

0 comments on commit 6b1ebff

Please sign in to comment.