Merged
Conversation
'git diff --exit-code' only inspects tracked files, so when 'make gen' produces new Markdown (e.g. for a new resource or data source), the check passes while the generated file remains uncommitted. Switch the check to 'git status --porcelain' so both modifications and untracked output fail the step, and print the offending paths and diff for easier debugging. Generated by Coder Agents on behalf of @zedkipp.
d8aab13 to
a49e0cd
Compare
dylanhuff-at-coder
approved these changes
Apr 24, 2026
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
The "Lint gen" step runs
make genand thengit diff --exit-code. Thatcheck only inspects tracked files, so when
make genproduces a brandnew Markdown doc (e.g. for a new resource or data source added via
terraform-plugin-docs), the generated file stays untracked and CIpasses while the author's local
docs/is the only place the fileexists.
Reproducing on a clean
main:Switch to
git status --porcelain, which reports modifications anduntracked output, and print the offending paths and diff so the failure
is actionable.
Generated by Coder Agents on behalf of @zedkipp.
Originally discovered this problem here: #501 (comment)