Skip to content

fix: drop the dead HUGO_VERSION pin from the Netlify config - #2110

Merged
markdumay merged 1 commit into
mainfrom
fix/drop-dead-hugo-version-pin
Aug 2, 2026
Merged

fix: drop the dead HUGO_VERSION pin from the Netlify config#2110
markdumay merged 1 commit into
mainfrom
fix/drop-dead-hugo-version-pin

Conversation

@markdumay

Copy link
Copy Markdown
Collaborator

Problem

Netlify installed Hugo 0.153.1 on every build and then never used it.

The build invokes hugo from an npm script, which resolves to node_modules/.bin/hugo from the hugo-extended dependency — shadowing the binary Netlify installed. So the pin was adrift from the version that actually ran, and cost a pointless download each build. Anyone reading the Netlify config to find out which Hugo builds this project got the wrong answer.

This was found via a gethinode.com deploy log showing both halves at once: Hugo version set to 0.153.1 followed by hugo v0.164.0+extended.

Changes

Remove HUGO_VERSION, leaving package.json as the single pin. A comment records why the key is absent so it does not get restored later.

Where netlify.toml is generated from data/netlify.toml (do-not-modify header), the source file is edited and the generated output updated to match — a deletion-only change.

Verification

The mechanism was verified end-to-end in gethinode.com: regenerating with no change reproduced the committed netlify.toml byte-for-byte, and regenerating after the removal produced exactly one deleted line, with no module-supplied HUGO_VERSION merging back in to replace it.

Each repo in this sweep was checked to confirm hugo-extended is a dependency and the Netlify build command routes through npm/pnpm scripts before the key was touched. Repos without an npm Hugo (gethinode/customization-demo, gethinode/version-demo) were deliberately excluded — their pin is load-bearing.

🤖 Generated with Claude Code

Netlify installed Hugo 0.153.1 on every build and then never used it. The
build invokes `hugo` from an npm script, which resolves to
node_modules/.bin/hugo provided by the hugo-extended dependency, so the
binary Netlify downloads for HUGO_VERSION is discarded.

The pin therefore only created drift between the version anyone reading
the Netlify config would trust and the binary that actually ran, plus a
pointless download on every build. package.json remains the single pin.

Remove the key from data/netlify.toml, the real source: netlify.toml is
generated from it and carries a do-not-modify header. The generated output
is regenerated to match.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@netlify

netlify Bot commented Aug 2, 2026

Copy link
Copy Markdown

Deploy Preview for gethinode-demo ready!

Name Link
🔨 Latest commit 3e22892
🔍 Latest deploy log https://app.netlify.com/projects/gethinode-demo/deploys/6a6f22d1471ef20008c8ef2a
😎 Deploy Preview https://deploy-preview-2110--gethinode-demo.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@markdumay
markdumay enabled auto-merge August 2, 2026 11:01
@markdumay
markdumay merged commit 994e889 into main Aug 2, 2026
17 checks passed
@markdumay

Copy link
Copy Markdown
Collaborator Author

🎉 This PR is included in version 3.16.2 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@markdumay
markdumay deleted the fix/drop-dead-hugo-version-pin branch August 2, 2026 11:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant