Compare commits

..
2 Commits
Author SHA1 Message Date
valknarandClaude Sonnet 5 672a624fa5 fix: replace deprecated languageCode/Site.LanguageCode with locale
Hugo v0.158.0 deprecated both in favor of the locale config key and
.Site.Language.Locale, matching pivoine.art's config.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01S3xLyuoN6uzfCYBo8kVoSn
2026-09-13 21:30:40 +02:00
valknarandClaude Sonnet 5 3166caf6a1 build: switch to native Hugo TailwindCSS pipeline, align Dockerfile with pivoine.art
Replaces the PostCSS + autoprefixer toolchain with Hugo's native
css.TailwindCSS pipe (via @tailwindcss/cli), matching the setup already
in use on pivoine.art. Dockerfile now builds on hugomods/hugo with a
matched Hugo/Node version instead of manually installing Hugo onto
node:22-alpine.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01S3xLyuoN6uzfCYBo8kVoSn
2026-09-13 21:29:52 +02:00
8 changed files with 275 additions and 549 deletions
+9 -14
View File
@@ -1,25 +1,20 @@
# ── Stage 1: builder ──────────────────────────────────────────────────────── # ── Stage 1: builder ────────────────────────────────────────────────────────
FROM node:22-alpine AS builder # hugomods image bundles Hugo Extended + Node at matching, tested versions —
# Hugo's css.TailwindCSS execs node_modules/.bin/tailwindcss during the build,
# Install Hugo extended + build tools # and pnpm-workspace.yaml's preferSymlinkedExecutables makes that a plain
RUN apk add --no-cache \ # symlink Hugo's exec-security check accepts (see layouts/partials/head.html).
curl \ FROM hugomods/hugo:debian-node-0.165.0 AS builder
git \
libc6-compat \
&& HUGO_VERSION=0.147.2 \
&& curl -sSL "https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.tar.gz" \
| tar -xz -C /usr/local/bin hugo
# Install pnpm # Install pnpm
RUN corepack enable && corepack prepare pnpm@latest --activate RUN npm install -g pnpm
WORKDIR /app WORKDIR /app
# Install dependencies # Copy package files first (for layer caching)
COPY package.json pnpm-lock.yaml* ./ COPY package.json pnpm-lock.yaml pnpm-workspace.yaml ./
RUN pnpm install --frozen-lockfile RUN pnpm install --frozen-lockfile
# Copy source # Copy source files
COPY . . COPY . .
# Build site # Build site
+4 -1
View File
@@ -1,5 +1,5 @@
baseURL = "https://bar.pivoine.art/" baseURL = "https://bar.pivoine.art/"
languageCode = "en-us" locale = "en-US"
title = "Bar Pivoine" title = "Bar Pivoine"
copyright = "© 2026 Bar Pivoine" copyright = "© 2026 Bar Pivoine"
@@ -36,6 +36,9 @@ noClasses = true
[build] [build]
writeStats = true writeStats = true
[security.exec]
allow = ['^(dart-)?sass$', '^go$', '^git$', '^node$', '^npx$', '^tailwindcss$']
[[menus.footer]] [[menus.footer]]
name = "Imprint" name = "Imprint"
url = "/imprint/" url = "/imprint/"
+1 -1
View File
@@ -1,5 +1,5 @@
<!doctype html> <!doctype html>
<html lang="{{ .Site.LanguageCode }}" class="scroll-smooth"> <html lang="{{ .Site.Language.Locale }}" class="scroll-smooth">
<head> <head>
{{- partial "head.html" . -}} {{- partial "head.html" . -}}
</head> </head>
+2 -2
View File
@@ -90,8 +90,8 @@
/> />
</noscript> </noscript>
<!-- CSS via Hugo Pipes + PostCSS + Tailwind v4 --> <!-- CSS via Hugo Pipes + Tailwind v4 (native css.TailwindCSS, no PostCSS) -->
{{- $css := resources.Get "css/main.css" | css.PostCSS -}} {{- $css := resources.Get "css/main.css" | css.TailwindCSS -}}
{{- if eq hugo.Environment "production" -}} {{- if eq hugo.Environment "production" -}}
{{- $css = $css | minify | fingerprint "sha256" -}} {{- $css = $css | minify | fingerprint "sha256" -}}
{{- end -}} {{- end -}}
+1 -4
View File
@@ -11,10 +11,7 @@
"format:check": "prettier --check \"layouts/**/*.html\" \"assets/**/*.css\" \"assets/**/*.js\" \"content/**/*.md\" \"*.toml\"" "format:check": "prettier --check \"layouts/**/*.html\" \"assets/**/*.css\" \"assets/**/*.js\" \"content/**/*.md\" \"*.toml\""
}, },
"devDependencies": { "devDependencies": {
"@tailwindcss/postcss": "^4.0.0", "@tailwindcss/cli": "^4.0.0",
"autoprefixer": "^10.4.0",
"postcss": "^8.5.0",
"postcss-cli": "^11.0.0",
"prettier": "^3.8.3", "prettier": "^3.8.3",
"prettier-plugin-go-template": "^0.0.15", "prettier-plugin-go-template": "^0.0.15",
"prettier-plugin-toml": "^2.0.6", "prettier-plugin-toml": "^2.0.6",
+255 -521
View File
File diff suppressed because it is too large Load Diff
+3
View File
@@ -0,0 +1,3 @@
preferSymlinkedExecutables: true
allowBuilds:
'@parcel/watcher': true
-6
View File
@@ -1,6 +0,0 @@
module.exports = {
plugins: {
"@tailwindcss/postcss": {},
autoprefixer: {},
},
};