move sass to Hugo pipes (#16028)

* move sass to Hugo pipes

* update hugo version to match new build container
This commit is contained in:
Craig Box 2024-12-04 05:33:20 +13:00 committed by GitHub
parent 0e7b343d88
commit 18bca5cb1a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
61 changed files with 7 additions and 5 deletions

View File

@ -117,7 +117,11 @@
<meta name="theme-color" content="#466BB0">
<!-- style sheets -->
<link rel="stylesheet" href="/css/all.css">
{{- $opts := dict "transpiler" "libsass" "targetPath" "css/style.css" -}}
{{- with resources.Get "sass/_all.scss" | toCSS $opts | minify | fingerprint -}}
<link rel="stylesheet" href="{{ .Permalink }}" integrity="{{ .Data.Integrity }}" crossorigin="anonymous">
{{- end -}}
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Barlow:ital,wght@0,400;0,500;0,600;0,700;1,400;1,600&display=swap">

View File

@ -2,7 +2,7 @@
publish = "public"
[build.environment]
HUGO_VERSION = "0.133.0"
HUGO_VERSION = "0.139.3"
NODE_VERSION = "18.18.2"
BUILD_WITH_CONTAINER = "0"
GO_VERSION = "1.21.3"

View File

@ -16,10 +16,8 @@
set -e
mkdir -p generated/css generated/js generated/img tmp/js
mkdir -p generated/js generated/img tmp/js
sass src/sass/_all.scss all.css -s compressed --no-source-map
mv all.css* generated/css
tsc
babel --source-maps --minified --no-comments --presets minify \