Repository navigation
Exclude generator scripts and draft outputs from site bundles - #1052
Merged
Merged
Conversation
Contributor
|
Contributor
✅ Spell Check PassedNo spelling issues found when checking 4 changed file(s)! 🎉 |
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 2 files
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
…in a unit test The test now reads ignoreFiles from config.toml and checks that every script and draft under content/ is ignored while pages and bundle assets are not. It runs in milliseconds and needs no Hugo. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 1 file (changes from recent commits).
Reply with feedback, questions, or to request a fix.
View guided diff | Turn on auto-fix | Re-trigger cubic
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.
Hugo currently publishes generator scripts and a draft output from content bundles. Extend the existing
ignoreFilesconfiguration to exclude.pyand.mdOUTfiles, leaving their source locations intact.Fixes #976.
The dedicated regression test builds the site (or accepts an existing build through
FORRT_TEST_BUILD_DIR), checks that these file types are absent, and verifies that the resources/summaries/reference pages, syllabus PDF and glossary JSON remain published.Verification
hugo --destination "$PWD/scratch-bundle-exclusions/build" --cacheDir "$PWD/scratch-bundle-exclusions/cache"build withHUGO_RESOURCEDIRset inside the same scratch directory: passed. Local Hugo 0.164.0 extended; CI pins 0.158.0, which was not run locally. Existing Hugo deprecation warnings remain.python3 scripts/check_seo_html.py scratch-bundle-exclusions/build: all 11 hard checks passed; report-only findings match the baseline.python3 scripts/rebrand/check_source_rules.py --base origin/main: passed after commit; no generated-path changes.FORRT_TEST_BUILD_DIR="$PWD/scratch-bundle-exclusions/build" python3 -m unittest discover -s scripts/tests: 86 tests passed.python3 -m unittest discover -s scripts/tests -p test_bundle_exclusions.py: both tests passed, including an independent Hugo build. Against the baseline build, the exclusion test failed on exactly the five reported files while the preservation test passed.python3 scripts/spell_check/check_spelling.py, using scratch-local codespell: 163 existing findings across 107 unchanged files. Direct codespell on both changed files passed. No unrelated spelling fixes included.git diff --checkpassed.Comparison expectations
Claude approved explicit
scripts/rebrand/allowed_changes.txtentries for these five non-page outputs. The full matched baseline/candidate comparison now passes: 4,710 reference files, 4,705 retained outputs, no unexpected URL, structured-data or SEO differences. All 46 comparison unit tests and the source-rules check pass; the added lines pass codespell. Protected #1042 remains untouched:resources/resource.pysummaries/summaries.pyglossary/_create_glossaries.pyglossary/_build_references.pyreplication-hub/submit/submit.mdOUTUI decision needed
None. This change only excludes non-page source/draft files from publication; retained output is unchanged.
🤖 Generated by GPT-6.1 Sol (Codex); review and UI decisions by Claude Code
Summary by cubic
Prevents Hugo from publishing generator scripts (
.py) and draft outputs (.mdOUT) from content bundles by extendingignoreFilesinconfig/_default/config.toml; source files stay in the repo. Fixes #976.scripts/rebrand/allowed_changes.txtso Doors' comparison stays clean.ignoreFilesand verifies all.py/.mdOUTfiles undercontent/are ignored while pages and bundle assets are not; it runs without Hugo.Written for commit e74d3c0. Summary will update on new commits.