fix: drop workflow-file PUT that 404s on freshly created split repos#87
Merged
Merged
Conversation
The sync-split-repo-config.sh script PUT a close-pull-requests workflow file to each split repo via the GitHub contents API. On a repo created seconds earlier by gh repo create, the contents API returns 404 "This repository is empty." because there is no default-branch commit yet, which killed the setup job and prevented the split matrix from running (observed on the PR #86 release for marko-database-readwrite). The workflow file was effectively dead code anyway: subtree splits force-push the package directory to refs/heads/main and refs/heads/develop on every release, so the workflow file never survived on any working split repo. Removing the PUT keeps only the settings PATCH (homepage, has_projects), which works fine on empty repos. The actual repo content lands via the split matrix's git push, which can bootstrap an empty repo. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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
bin/sync-split-repo-config.shPUT aclose-pull-requests.ymlworkflow file to each split repo via the GitHub contents API. On a repo created seconds earlier bygh repo create, the contents API returns 404 "This repository is empty." because there's no default-branch commit yet. That killed thesetupjob insplit.ymland prevented thesplitmatrix from running (hit on the PR feat(database-readwrite): add marko/database-readwrite package #86 release formarko-database-readwrite).refs/heads/mainandrefs/heads/developon every release, so the file never survived on any working split repo (verified againstmarko-authentication). Removing the PUT keeps only the settings PATCH (homepage,has_projects), which works fine on empty repos.bin/split-repo-workflow.ymltemplate.Test plan
--silent 2>/dev/null || true, so it's safe on any repo state.EXISTING_REPOScheck will skip create+sync formarko-database-readwrite(repo already exists), then the matrix'sgit pushpopulates it.🤖 Generated with Claude Code