Repository navigation
Add self-documenting make help target and reusable Makefile skill - #1
Merged
Merged
Conversation
…targets Why: - Provides a reusable on-demand workflow for annotating Makefile targets and inserting a self-documenting `make help` target What changed: - .github/skills/makefile-help/SKILL.md: new skill with 4-step procedure (read, annotate, insert help target, validate) - .github/skills/makefile-help/assets/help-target.mk: Makefile snippet with .DEFAULT_GOAL, .PHONY, and grep/awk help recipe Compatibility: - Backward-compatible because only new files are added; no existing Makefile, source, or configuration is modified Validation: - Frontmatter YAML is valid; asset is syntactically correct GNU make; skill appears as /makefile-help slash command in VS Code Copilot
Why: - Developers had no way to discover available make targets without reading the Makefile directly What changed: - Makefile: added help target with grep/awk recipe that prints all targets annotated with ## comments - Makefile: set .DEFAULT_GOAL := help so bare `make` shows usage - Makefile: added ## inline descriptions to build, test, vet, clean, run - Makefile: added help to .PHONY declaration Compatibility: - Backward-compatible because no Go source, public API, or compiled binary behavior is changed; all existing targets are preserved unchanged Validation: - `make help` confirmed; all 6 targets listed with correct descriptions - `make build`, `make test`, `make vet`, `make run`, `make clean` recipes are unmodified
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.
Summary
Developers cloning the project had no discoverable way to learn what
maketargets were available without reading the Makefile directly. This PR adds ahelptarget that auto-generates a target listing from inline## descriptioncomments, making the project more approachable for new contributors and portfolio viewers. It also packages the pattern as a reusable Copilot skill so the same workflow can be applied to other Makefiles in one command.Motivation / Context
makepreviously defaulted tobuildwith no usage guidance.target:: ## …) would require a pattern adjustment.What Changed
Build tooling (
Makefile)helptarget with grep/awk recipe that prints all## description-annotated targets in colour-coded, aligned columns..DEFAULT_GOAL := helpso baremakeprints usage instead of building.## descriptioninline comments to all five existing targets (build,test,vet,clean,run).helpto the.PHONYdeclaration.Developer tooling (
makefile-help)SKILL.md: VS Code Copilot on-demand skill (/makefile-help) with a 4-step procedure — read, annotate, insert, validate.assets/help-target.mk: reusable drop-in Makefile snippet bundled with the skill.How It Was Tested / Verified
make help— all 6 targets listed with correct descriptions (output captured below).make build— compiles cleanly, no new warnings.make test— all 5 package test suites pass with-raceflag (config,grid,robot,simulation,tui).make vet— no issues reported.Screenshots / Output Samples
Checklist
make helpis self-documenting; READMEmakesection can optionally referencemake helpin a follow-up