A publish that only adds a file has to say so - #284
Merged
Merged
Conversation
`git diff --quiet` ignores untracked files. A publish whose only change is a *new* file — a Space gaining a module, which is exactly what every one of them has done — therefore found the clone clean, printed "the Space already serves this" and exited 0 without pushing. Nothing distinguishes that from the case it was written for. Staging before comparing, and comparing the index, sees additions, deletions and modifications alike. `git add -A` moves up from just under the commit; nothing else changes. Assisted-by: Claude:claude-opus-5[1m]
Coverage71.62% lines on this branch, against a floor of 70%. Per-file |
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.
scripts/publish-space.shdecides whether there is anything to push withgit diff --quiet, which ignores untracked files. A publish whose only change is a new file finds the clone clean, prints "the Space already serves this" and exits 0 without pushing — and that sentence is the one it prints on success, so there is nothing to notice.Every Space in
spaces/has gained a module at some point, so this is the ordinary case rather than a corner of it, and it fails in the direction of looking fine.git add -Amoves up from just under the commit and the check becomesgit diff --cached --quiet, which sees additions, deletions and modifications alike. Nothing else about the script changes.Found while establishing that #223 is superseded — its Space source was replaced by the push-based one in 4e3506b, and of the three publisher bugs it recorded this is the one main still has. #223 is closed.
🤖 Generated with Claude Code