Auto-generate the hugoautogen workspace via a postinstall hook#474
Merged
Conversation
- Replaces the explicit `install:all` double-install with an automatic `postinstall` hook, so a single `npm install` regenerates and installs the git-ignored `hugoautogen` workspace — restoring a plain `npm install` for contributors, Netlify, and CI. - Adds `postinstall`: `npm run update:docsy:pack -- --ignore-scripts`; the `--ignore-scripts` on the nested install keeps the hook from recursing. - Reverts `netlify.toml`, the links workflow, and the README to a plain `npm install`, and drops the now-redundant `install:all` script. - Documents in the README why this single install also builds the theme's npm asset workspace (Hugo is sourced via npm; the theme's assets are discovered through Hugo modules).
- Notes that `npm install` now requires Go, since the `postinstall` hook runs `hugo mod npm pack`, and broadens the existing `go`-not-found troubleshooting entry to say it can surface at install time, not only when serving. - Aligns the local-clone command to `hugo serve`, matching the rest of the README and the `serve` npm script. - Formats the `VERSION` placeholder as italic code, per the Google placeholder style.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
install:alldouble-install with an automaticpostinstallhook, so a singlenpm installregenerates and installs the git-ignoredhugoautogenworkspace — restoring a plainnpm installfor contributors, Netlify, and CI.postinstallthat runsupdate:docsy:pack(hugo mod npm pack && npm install --ignore-scripts); the--ignore-scriptson the nested install keeps the hook from recursing.hugo,npm,&&), with no shell-specific syntax.netlify.toml, the links workflow, and the README to a plainnpm install, and drops the now-redundantinstall:allscript.