Add folder size check workflow to prevent oversized directories#161
Merged
Miyamura80 merged 1 commit intomainfrom Apr 23, 2026
Merged
Add folder size check workflow to prevent oversized directories#161Miyamura80 merged 1 commit intomainfrom
Miyamura80 merged 1 commit intomainfrom
Conversation
Co-Authored-By: Claude Opus 4.6 <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
.github/workflows/folder-size.yaml): runs on PRs touching.pyfiles, checks that no single directory has too many flat Python siblings (warn at 20, error at 35)..github/workflows/large-files.yaml): runs on PRs touching.pyfiles, checks that no source file exceeds the line-count threshold (warn at 500, error at 800).scripts/check_folder_sizes.sh,scripts/check_large_files.sh): reusable scripts consumed by both GitHub Actions and local prek hooks. Support--allmode and per-file mode, produce GitHub step summaries, and respect grandfathered/excluded paths.prek.toml): addedcheck-large-filesandcheck-folder-sizeshooks so the same checks run locally on every commit..claude/agents/folder-refactor-advisor.md,.codex/agents/folder-refactor-advisor.toml): advisory-only agent that diagnoses oversized folders and proposes three concrete subfolder restructurings when the CI check fails.Test plan
.pyfiles and verify thefolder-sizeworkflow fails.pyfile >800 lines and verify thelarge-filesworkflow failsscripts/check_folder_sizes.sh --allandscripts/check_large_files.sh --alllocally and confirm clean outputgit commitfor staged.pyfiles🤖 Generated with Claude Code