[chore]: standardize makefile to npm run calls#227
Conversation
…e makefile recipes to utilize npm scripts Signed-off-by: Lenox Wiltshire <lenoxwiltshire@gmail.com>
|
🚀 Preview deployment: https://layer5io.github.io/academy-theme/pr-preview/pr-227/ |
There was a problem hiding this comment.
Code Review
This pull request introduces an .htmltest.yml configuration for link checking, refactors the Makefile to delegate tasks to npm scripts, and updates package.json with new scripts for building, formatting with Prettier, and updating the theme. Feedback on these changes highlights that the _check:links script only echoes the command instead of executing it, disabling link checking. Additionally, it is recommended to define a lint:fix script in package.json, add markdownlint-cli2 to devDependencies for reproducible linting, and update the Makefile to invoke this script via npm rather than using npx directly.
Important
The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.
…update package.json metadata Signed-off-by: Lenox Wiltshire <lenoxwiltshire@gmail.com>
Signed-off-by: Lenox Wiltshire <lenoxwiltshire@gmail.com>
Signed-off-by: Lenox Wiltshire <lenoxwiltshire@gmail.com>
Notes for Reviewers
This PR fixes #226
Summary
Makefile
Bug fixes
cleanranhugo --cleanDestinationDir— a build, not a clean.public/andresources/were never removed. Nownpm run clean.buildran barehugo(a production build, no clean) under a "local machine" label. Nownpm run build(dev build with clean + drafts/future content).Behavior
site:hugo server -D -F→npm run site(adds--cleanDestinationDir,-Efor expired content, and--minify).lint-fix: no longer installsmarkdownlint-cli2globally (npm install -g); usesnpx --yes. Scope narrowed from**/*.mdtocontent/**/*.md.Added
include .github/build/Makefile.core.mk(the old file only includedMakefile.show-help.mk).build-preview,build-production,site-no-watch,check-links,format,format-check,check-deps,theme-update.HTMLTEST_VERSION ?= latest(+export) — single place to pin htmltest.check-go check-depsprerequisites on all build/serve/theme targets (previously onlysitehadcheck-go).Structural
npm runinstead of callinghugodirectly, makingpackage.jsonthe single source of Hugo flags.package.json
Removed
--on_buildandbuild— no-opscheck:links:all,precheck:links:all— orphaned; nothing invoked themRenamed
_serve→_site,serve→siteupdate:dep→update:pkg:dep,update:hugo→update:pkg:hugoAdded
site,site:no-watch,format,format:check,update:themeprettier@3.8.3Behavior
build:production: added--gc(cache garbage collection; output unchanged)hugo serverinstead of theservealias, and--renderToMemorywas dropped, so serve now writes topublic/_check:links:IMPLEMENTATION PENDING→Skipped: go run …htmltest… -s. Link checking remains a no-op, now explicitly labelled.Dependencies
autoprefixerfloor^10.4.21→^10.5.0postcssfloor^8.5.14→^8.5.15prettier@3.8.3package-lock.jsonregenerated to matchBreaking
npm run serve,_serve,update:dep,update:hugo,check:links:allno longer exist.make buildnow cleans the destination directory and includes drafts/future content; usemake build-productionfor production output.Signed commits